CodeNarc Report

Report title:
Date:Apr 26, 2024, 3:30:15 PM
Generated with:CodeNarc v3.4.0

Summary

PackageTotal FilesFiles with ViolationsPriority 1Priority 2Priority 3
All Packages585151-4103974
org/apache/ofbiz/accounting/accounting18----
org/apache/ofbiz/accounting/admin3----
org/apache/ofbiz/accounting/agreement2----
org/apache/ofbiz/accounting/ap/invoices2----
org/apache/ofbiz/accounting/ar1----
org/apache/ofbiz/accounting/budget1----
org/apache/ofbiz/accounting/chartofaccounts1----
org/apache/ofbiz/accounting/fixedasset2----
org/apache/ofbiz/accounting/invoice8----
org/apache/ofbiz/accounting/ledger1----
org/apache/ofbiz/accounting/order1----
org/apache/ofbiz/accounting/payment8----
org/apache/ofbiz/accounting/period21--2
org/apache/ofbiz/accounting/rate1----
org/apache/ofbiz/accounting/reports13----
org/apache/ofbiz/accounting/transaction3----
org/apache/ofbiz/assetmaint/assetmaint33--32
org/apache/ofbiz/assetmaint/assetmaint/test1----
org/apache/ofbiz/assetmaint/workeffort11--16
org/apache/ofbiz/base/test1----
org/apache/ofbiz/bi51-3-
org/apache/ofbiz/common121-11
org/apache/ofbiz/common/email1----
org/apache/ofbiz/common/permission1----
org/apache/ofbiz/commonext/ofbizsetup5----
org/apache/ofbiz/commonext/template1----
org/apache/ofbiz/content1----
org/apache/ofbiz/content/cms5----
org/apache/ofbiz/content/content63-120
org/apache/ofbiz/content/contentsetup1----
org/apache/ofbiz/content/data11--1
org/apache/ofbiz/content/datasetup1----
org/apache/ofbiz/content/layout1----
org/apache/ofbiz/content/permission1----
org/apache/ofbiz/content/print1----
org/apache/ofbiz/content/survey32--2
org/apache/ofbiz/content/website3----
org/apache/ofbiz/ebay44-234
org/apache/ofbiz/ecommerce44-344
org/apache/ofbiz/ecommerce/cart22-220
org/apache/ofbiz/ecommerce/catalog76-24239
org/apache/ofbiz/ecommerce/content43-652
org/apache/ofbiz/ecommerce/customer1515-43216
org/apache/ofbiz/ecommerce/forum1313-19495
org/apache/ofbiz/ecommerce/includes11--28
org/apache/ofbiz/ecommerce/order1816-52393
org/apache/ofbiz/ecommerce/order/test1----
org/apache/ofbiz/ecommerce/shoppinglist11-1067
org/apache/ofbiz/entityext1----
org/apache/ofbiz/example32--13
org/apache/ofbiz/humanres/category1----
org/apache/ofbiz/lucene/content44-835
org/apache/ofbiz/manufacturing/bom31--1
org/apache/ofbiz/manufacturing/jobshopmgt136--6
org/apache/ofbiz/manufacturing/mrp1----
org/apache/ofbiz/manufacturing/reports10----
org/apache/ofbiz/manufacturing/routing4----
org/apache/ofbiz/marketing/marketing/contact1----
org/apache/ofbiz/marketing/marketing/reports4----
org/apache/ofbiz/marketing/marketing/test1----
org/apache/ofbiz/marketing/sfa2----
org/apache/ofbiz/marketing/sfa/account1----
org/apache/ofbiz/marketing/sfa/lead1----
org/apache/ofbiz/order1----
org/apache/ofbiz/order/allocationplan3----
org/apache/ofbiz/order/communications1----
org/apache/ofbiz/order/entry20----
org/apache/ofbiz/order/entry/cart3----
org/apache/ofbiz/order/entry/catalog15----
org/apache/ofbiz/order/lookup1----
org/apache/ofbiz/order/order206--7
org/apache/ofbiz/order/order/test6----
org/apache/ofbiz/order/orderReturn44-4-
org/apache/ofbiz/order/quote5----
org/apache/ofbiz/order/reports1----
org/apache/ofbiz/order/request3----
org/apache/ofbiz/order/requirement4----
org/apache/ofbiz/order/setup1----
org/apache/ofbiz/order/shoppinglist1----
org/apache/ofbiz/order/task1----
org/apache/ofbiz/party1----
org/apache/ofbiz/party/communication7----
org/apache/ofbiz/party/contact1----
org/apache/ofbiz/party/party263--3
org/apache/ofbiz/party/party/test4----
org/apache/ofbiz/party/visit2----
org/apache/ofbiz/passport/login11-28
org/apache/ofbiz/pricat/pricat22--49
org/apache/ofbiz/product/catalog5----
org/apache/ofbiz/product/catalog/category6----
org/apache/ofbiz/product/catalog/config2----
org/apache/ofbiz/product/catalog/feature3----
org/apache/ofbiz/product/catalog/find6----
org/apache/ofbiz/product/catalog/imagemanagement9----
org/apache/ofbiz/product/catalog/lookup1----
org/apache/ofbiz/product/catalog/price1----
org/apache/ofbiz/product/catalog/product11----
org/apache/ofbiz/product/catalog/promo1----
org/apache/ofbiz/product/catalog/store2----
org/apache/ofbiz/product/catalog/thesaurus1----
org/apache/ofbiz/product/facility/facility13----
org/apache/ofbiz/product/facility/inventory7----
org/apache/ofbiz/product/facility/returns1----
org/apache/ofbiz/product/facility/shipment17----
org/apache/ofbiz/product/facility/storage1----
org/apache/ofbiz/product/product/catalog1----
org/apache/ofbiz/product/product/category2----
org/apache/ofbiz/product/product/config1----
org/apache/ofbiz/product/product/cost1----
org/apache/ofbiz/product/product/feature1----
org/apache/ofbiz/product/product/imagemanagement11-1-
org/apache/ofbiz/product/product/inventory2----
org/apache/ofbiz/product/product/price1----
org/apache/ofbiz/product/product/product2----
org/apache/ofbiz/product/product/promo3----
org/apache/ofbiz/product/product/store1----
org/apache/ofbiz/product/product/subscription1----
org/apache/ofbiz/product/product/supplier1----
org/apache/ofbiz/product/product/test12----
org/apache/ofbiz/product/shipment4----
org/apache/ofbiz/projectmgr97-29184
org/apache/ofbiz/scrum2222-1931849
org/apache/ofbiz/service/engine1----
org/apache/ofbiz/service/test1----
org/apache/ofbiz/shipment/product/test1----
org/apache/ofbiz/webpos33--15
org/apache/ofbiz/webpos/cart11-462
org/apache/ofbiz/webpos/catalog22-118
org/apache/ofbiz/webpos/customer11--27
org/apache/ofbiz/webpos/manager11--8
org/apache/ofbiz/webpos/search22-221
org/apache/ofbiz/webtools/artifactinfo2----
org/apache/ofbiz/webtools/cache3----
org/apache/ofbiz/webtools/datafile1----
org/apache/ofbiz/webtools/entity11----
org/apache/ofbiz/webtools/geo1----
org/apache/ofbiz/webtools/labelmanager43--5
org/apache/ofbiz/webtools/log2----
org/apache/ofbiz/webtools/service71--1
org/apache/ofbiz/webtools/stats2----
org/apache/ofbiz/workeffort/ical1----
org/apache/ofbiz/workeffort/workeffort/calendar5----
org/apache/ofbiz/workeffort/workeffort/content1----
org/apache/ofbiz/workeffort/workeffort/find2----
org/apache/ofbiz/workeffort/workeffort/request1----
org/apache/ofbiz/workeffort/workeffort/workeffort1----

Package: org.apache.ofbiz.accounting.period

➥ GPeriodServices.groovy

Rule NamePriorityLine #Source Line / Message
BlockEndsWithBlankLine355

[MSG]Code block ends with a blank line.

FileEndsWithoutNewline389

[SRC]}

[MSG]File GPeriodServices.groovy does not end with a newline

Package: org.apache.ofbiz.assetmaint.assetmaint

➥ EditMaint.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGString329

[SRC]fixedAssetMaint = from("FixedAssetMaint").where("schedul..queryFirst()

[MSG]The String 'FixedAssetMaint' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]fixedAssetMaint = from("FixedAssetMaint").where("schedul..queryFirst()

[MSG]The String 'scheduleWorkEffortId' can be wrapped in single quotes instead of double quotes

➥ FixedAssetMaintServices.groovy

Rule NamePriorityLine #Source Line / Message
ConsecutiveBlankLines320

[MSG]File FixedAssetMaintServices.groovy has consecutive blank lines

JavadocEmptyReturnTag326

[SRC]* @return

[MSG]The javadoc @return tag is empty

MethodReturnTypeRequired328

[SRC]def createFixedAssetMaintUpdateWorkEffort() {

[MSG]Method "createFixedAssetMaintUpdateWorkEffort" has a dynamic return type

NoDef328

[SRC]def createFixedAssetMaintUpdateWorkEffort() {

[MSG]def for method return type should not be used

TrailingWhitespace330

[SRC]

[MSG]Line ends with whitespace characters

JavadocEmptyReturnTag343

[SRC]* @return

[MSG]The javadoc @return tag is empty

MethodReturnTypeRequired346

[SRC]def updateFixedAssetMaintAndWorkEffort() {

[MSG]Method "updateFixedAssetMaintAndWorkEffort" has a dynamic return type

NoDef346

[SRC]def updateFixedAssetMaintAndWorkEffort() {

[MSG]def for method return type should not be used

JavadocEmptyReturnTag364

[SRC]* @return

[MSG]The javadoc @return tag is empty

MethodReturnTypeRequired366

[SRC]def createWorkEffortAndAssocWithParent() {

[MSG]Method "createWorkEffortAndAssocWithParent" has a dynamic return type

NoDef366

[SRC]def createWorkEffortAndAssocWithParent() {

[MSG]def for method return type should not be used

JavadocEmptyReturnTag374

[SRC]* @return

[MSG]The javadoc @return tag is empty

MethodReturnTypeRequired376

[SRC]def assetMaintPermissionCheck() {

[MSG]Method "assetMaintPermissionCheck" has a dynamic return type

NoDef376

[SRC]def assetMaintPermissionCheck() {

[MSG]def for method return type should not be used

➥ PrintFixedAssetMaint.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGString321

[SRC]facility = fixedAsset.getRelatedOne("LocatedAtFacility", false)

[MSG]The String 'LocatedAtFacility' can be wrapped in single quotes instead of double quotes

UnnecessaryGString324

[SRC]fixedAssetIdents = from("FixedAssetIdent").where("fixedA...queryList()

[MSG]The String 'FixedAssetIdent' can be wrapped in single quotes instead of double quotes

UnnecessaryGString324

[SRC]fixedAssetIdents = from("FixedAssetIdent").where("fixedA...queryList()

[MSG]The String 'fixedAssetId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString325

[SRC]fixedAssetIdentValue = ""

[MSG]The String '' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]fixedAssetIdentValue = fixedAssetIdentValue + " " + ident.idValue

[MSG]The String ' ' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]status = fixedAssetMaint.getRelatedOne("StatusItem", false)

[MSG]The String 'StatusItem' can be wrapped in single quotes instead of double quotes

UnnecessaryGString339

[SRC]intervalUom = fixedAssetMaint.getRelatedOne("IntervalUom", false)

[MSG]The String 'IntervalUom' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]productMaint = from("ProductMaint").where("productId", i..).queryOne()

[MSG]The String 'ProductMaint' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]productMaint = from("ProductMaint").where("productId", i..).queryOne()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]productMaint = from("ProductMaint").where("productId", i..).queryOne()

[MSG]The String 'productMaintSeqId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString353

[SRC]productMaintType = from("ProductMaintType").where("produ..).queryOne()

[MSG]The String 'ProductMaintType' can be wrapped in single quotes instead of double quotes

UnnecessaryGString353

[SRC]productMaintType = from("ProductMaintType").where("produ..).queryOne()

[MSG]The String 'productMaintTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]productMeterTypeDesc = ""

[MSG]The String '' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]productMeterType = from("ProductMeterType").where("produ..).queryOne()

[MSG]The String 'ProductMeterType' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]productMeterType = from("ProductMeterType").where("produ..).queryOne()

[MSG]The String 'productMeterTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]scheduleWorkEffort = fixedAssetMaint.getRelatedOne("Sche..ort", false)

[MSG]The String 'ScheduleWorkEffort' can be wrapped in single quotes instead of double quotes

Package: org.apache.ofbiz.assetmaint.workeffort

➥ EditWorkEfforts.groovy

Rule NamePriorityLine #Source Line / Message
CouldBeElvis325

[SRC]if (!maintHistSeqId) {

[MSG]Code could use elvis operator: maintHistSeqId = maintHistSeqId ?: parameters.maintHistSeqId

CouldBeElvis328

[SRC]if (!fixedAssetId) {

[MSG]Code could use elvis operator: fixedAssetId = fixedAssetId ?: parameters.fixedAssetId

CouldBeElvis331

[SRC]if (!workEffortId) {

[MSG]Code could use elvis operator: workEffortId = workEffortId ?: parameters.workEffortId

UnnecessaryGString341

[SRC]workEffort = from("WorkEffort").where("workEffortId", wo..).queryOne()

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString341

[SRC]workEffort = from("WorkEffort").where("workEffortId", wo..).queryOne()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

CouldBeElvis343

[SRC]if (!fixedAssetId) {

[MSG]Code could use elvis operator: fixedAssetId = fixedAssetId ?: workEffort.fixedAssetId

UnnecessaryGString347

[SRC]parentWorkEffort = from("WorkEffortAssoc").where("workEf..queryFirst()

[MSG]The String 'WorkEffortAssoc' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]parentWorkEffort = from("WorkEffortAssoc").where("workEf..queryFirst()

[MSG]The String 'workEffortIdTo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]parentWorkEffort = from("WorkEffortAssoc").where("workEf..queryFirst()

[MSG]The String 'WorkEffortAssoc' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]parentWorkEffort = from("WorkEffortAssoc").where("workEf..queryFirst()

[MSG]The String 'workEffortIdTo' can be wrapped in single quotes instead of double quotes

CouldBeElvis355

[SRC]if (!rootWorkEffortId) {

[MSG]Code could use elvis operator: rootWorkEffortId = rootWorkEffortId ?: workEffortId

UnnecessaryGString360

[SRC]fixedAssetMaint = from("FixedAssetMaint").where("schedul..queryFirst()

[MSG]The String 'FixedAssetMaint' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]fixedAssetMaint = from("FixedAssetMaint").where("schedul..queryFirst()

[MSG]The String 'scheduleWorkEffortId' can be wrapped in single quotes instead of double quotes

CouldBeElvis363

[SRC]if (!fixedAssetId) {

[MSG]Code could use elvis operator: fixedAssetId = fixedAssetId ?: fixedAssetMaint.fixedAssetId

UnnecessaryGString370

[SRC]fixedAsset = from("FixedAsset").where("fixedAssetId", fi..).queryOne()

[MSG]The String 'FixedAsset' can be wrapped in single quotes instead of double quotes

UnnecessaryGString370

[SRC]fixedAsset = from("FixedAsset").where("fixedAssetId", fi..).queryOne()

[MSG]The String 'fixedAssetId' can be wrapped in single quotes instead of double quotes

Package: org.apache.ofbiz.bi

➥ DimensionServices.groovy

Rule NamePriorityLine #Source Line / Message
AssignmentInConditional256

[SRC]while (iterator = listIterator.next()) {

[MSG]Assignment used as conditional value, which always results in true. Use the == operator instead

AssignmentInConditional272

[SRC]while (iterator = listIterator.next()) {

[MSG]Assignment used as conditional value, which always results in true. Use the == operator instead

AssignmentInConditional283

[SRC]while (iterator = listIterator.next()) {

[MSG]Assignment used as conditional value, which always results in true. Use the == operator instead

Package: org.apache.ofbiz.common

➥ CommonServicesScript.groovy

Rule NamePriorityLine #Source Line / Message
AssignmentInConditional2355

[SRC]while (party = parties.next()) {

[MSG]Assignment used as conditional value, which always results in true. Use the == operator instead

ImportFromSamePackage327

[SRC]import org.apache.ofbiz.common.CommonWorkers

Package: org.apache.ofbiz.content.content

➥ ContentSearchOptions.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage322

[SRC]import org.apache.ofbiz.content.content.ContentSearchSession

➥ ContentSearchResults.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.content.content.ContentSearchSession

ImportFromSamePackage322

[SRC]import org.apache.ofbiz.content.content.ContentSearchEvents

➥ ContentServicesScript.groovy

Rule NamePriorityLine #Source Line / Message
AssignmentInConditional2154

[SRC]while (content = contents.next()) {

[MSG]Assignment used as conditional value, which always results in true. Use the == operator instead

ImportFromSamePackage323

[SRC]import org.apache.ofbiz.content.content.ContentKeywordIndex

SpaceAfterOpeningBrace3601

[SRC]long contentsUpdated = contentCreatedList.stream().filte..'Y'}.count()

[MSG]The opening brace for the closure in class org.apache.ofbiz.content.content.None is not followed by a space or whitespace

SpaceBeforeClosingBrace3601

[SRC]long contentsUpdated = contentCreatedList.stream().filte..'Y'}.count()

[MSG]The closing brace for the closure in class org.apache.ofbiz.content.content.None is not preceded by a space or whitespace

JavadocMissingParamDescription3607

[SRC]* @param parentProductCategoryId

[MSG]The description for the javadoc @param tag is missing

JavadocEmptyReturnTag3608

[SRC]* @return

[MSG]The javadoc @return tag is empty

JavadocMissingParamDescription3625

[SRC]* @param contentId

[MSG]The description for the javadoc @param tag is missing

JavadocEmptyReturnTag3626

[SRC]* @return

[MSG]The javadoc @return tag is empty

BlockStartsWithBlankLine3650

[MSG]Code block starts with a blank line.

JavadocEmptyReturnTag3674

[SRC]* @return

[MSG]The javadoc @return tag is empty

UnnecessaryGString3687

[SRC]dataResource.removeRelated("ElectronicText")

[MSG]The String 'ElectronicText' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3688

[SRC]dataResource.removeRelated("ImageDataResource")

[MSG]The String 'ImageDataResource' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3689

[SRC]dataResource.removeRelated("OtherDataResource")

[MSG]The String 'OtherDataResource' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3690

[SRC]dataResource.removeRelated("VideoDataResource")

[MSG]The String 'VideoDataResource' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3691

[SRC]dataResource.removeRelated("DataResourceRole")

[MSG]The String 'DataResourceRole' can be wrapped in single quotes instead of double quotes

JavadocEmptyReturnTag3700

[SRC]* @return

[MSG]The javadoc @return tag is empty

SpaceAroundMapEntryColon3709

[SRC]textData : getElectronicTextResult.textData]

[MSG]The colon for the literal Map entry for key [textData] within class org.apache.ofbiz.content.content.None is not preceded by a match for regular expression [\S]

JavadocEmptyReturnTag3735

[SRC]* @return

[MSG]The javadoc @return tag is empty

Package: org.apache.ofbiz.content.data

➥ DataServicesScript.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage323

[SRC]import org.apache.ofbiz.content.data.DataResourceWorker

Package: org.apache.ofbiz.content.survey

➥ EditSurveyResponse.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.content.survey.SurveyWrapper

➥ ViewSurveyResponses.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.content.survey.SurveyWrapper

Package: org.apache.ofbiz.ebay

➥ EbayAdvancedSearch.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGString335

[SRC]ebayConfigList = from("EbayConfig").queryList()

[MSG]The String 'EbayConfig' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]prodCatalog = from("ProdCatalog").where("prodCatalogId",..).queryOne()

[MSG]The String 'ProdCatalog' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]prodCatalog = from("ProdCatalog").where("prodCatalogId",..).queryOne()

[MSG]The String 'prodCatalogId' can be wrapped in single quotes instead of double quotes

CouldBeElvis353

[SRC]if (!topCategory) {

[MSG]Code could use elvis operator: topCategory = topCategory ?: CatalogWorker.getCatalogTopCategoryId(request, currentCatalogId)

UnnecessaryGString357

[SRC]CategoryWorker.getRelatedCategories(request, "topLevelLi..egory, true)

[MSG]The String 'topLevelList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString358

[SRC]if (request.getAttribute("topLevelList")) {

[MSG]The String 'topLevelList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString359

[SRC]categoryList = request.getAttribute("topLevelList")

[MSG]The String 'topLevelList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]categoryIds = EntityUtil.getFieldListFromEntityList(cate..ryId", true)

[MSG]The String 'productCategoryId' can be wrapped in single quotes instead of double quotes

➥ EbayOrders.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGString322

[SRC]session.setAttribute("orderList", parameters.orderList)

[MSG]The String 'orderList' can be wrapped in single quotes instead of double quotes

➥ ProductsExportToEbayScript.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod263

[SRC]if (!"Y".equals(categoryCode.substring(0, 1)) && !"".equ..goryCode)) {

[MSG]Violation in class org.apache.ofbiz.ebay.None. Explicit call to Y.equals(categoryCode.substring(0, 1)) method can be rewritten as (Y == (categoryCode.substring(0, 1)))

ExplicitCallToEqualsMethod263

[SRC]if (!"Y".equals(categoryCode.substring(0, 1)) && !"".equ..goryCode)) {

[MSG]Violation in class org.apache.ofbiz.ebay.None. Explicit call to .equals(categoryCode) method can be rewritten as ( == (categoryCode))

BlankLineBeforePackage318

[MSG]Blank line precedes package declaration in file ProductsExportToEbayScript.groovy

UnnecessaryGString328

[SRC]webSiteList = from("WebSite").where("productStoreId", pr...queryList()

[MSG]The String 'WebSite' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]webSiteList = from("WebSite").where("productStoreId", pr...queryList()

[MSG]The String 'productStoreId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]webSite = from("WebSite").where("webSiteId", parameters...).queryOne()

[MSG]The String 'WebSite' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]webSite = from("WebSite").where("webSiteId", parameters...).queryOne()

[MSG]The String 'webSiteId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC]countryCode = "US"

[MSG]The String 'US' can be wrapped in single quotes instead of double quotes

UnnecessaryGString346

[SRC]eBayConfig = from("EbayConfig").where("productStoreId", ..).queryOne()

[MSG]The String 'EbayConfig' can be wrapped in single quotes instead of double quotes

UnnecessaryGString346

[SRC]eBayConfig = from("EbayConfig").where("productStoreId", ..).queryOne()

[MSG]The String 'productStoreId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString348

[SRC]context.webSiteUrl = webSite.getString("standardContentPrefix")

[MSG]The String 'standardContentPrefix' can be wrapped in single quotes instead of double quotes

TrailingWhitespace349

[SRC]

[MSG]Line ends with whitespace characters

TrailingWhitespace353

[SRC]

[MSG]Line ends with whitespace characters

SpaceAroundMapEntryColon355

[SRC]results = runService('getEbayCategories', [categoryCode ..uctStoreId])

[MSG]The colon for the literal Map entry for key [categoryCode] within class org.apache.ofbiz.ebay.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon355

[SRC]results = runService('getEbayCategories', [categoryCode ..uctStoreId])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.ebay.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon355

[SRC]results = runService('getEbayCategories', [categoryCode ..uctStoreId])

[MSG]The colon for the literal Map entry for key [productStoreId] within class org.apache.ofbiz.ebay.None is not preceded by a match for regular expression [\S]

TrailingWhitespace357

[SRC]

[MSG]Line ends with whitespace characters

TrailingWhitespace361

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString363

[SRC]if (!"Y".equals(categoryCode.substring(0, 1)) && !"".equ..goryCode)) {

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]if (!"Y".equals(categoryCode.substring(0, 1)) && !"".equ..goryCode)) {

[MSG]The String '' can be wrapped in single quotes instead of double quotes

UnnecessaryGString364

[SRC]context.hideExportOptions = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString366

[SRC]context.hideExportOptions = "N"

[MSG]The String 'N' can be wrapped in single quotes instead of double quotes

UnnecessaryGString369

[SRC]context.hideExportOptions = "N"

[MSG]The String 'N' can be wrapped in single quotes instead of double quotes

TrailingWhitespace370

[SRC]}

[MSG]Line ends with whitespace characters

➥ UpdatedEbayOrders.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGString321

[SRC]if (session.getAttribute("orderList")) {

[MSG]The String 'orderList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString322

[SRC]session.removeAttribute("orderList")

[MSG]The String 'orderList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString323

[SRC]return "success"

[MSG]The String 'success' can be wrapped in single quotes instead of double quotes

Package: org.apache.ofbiz.ecommerce

➥ EcommerceSetup.groovy

Rule NamePriorityLine #Source Line / Message
IfStatementBraces235

[SRC]if (catalogStyleSheet) globalContext.catalogStyleSheet =..ogStyleSheet

[MSG]The if statement lacks braces

IfStatementBraces237

[SRC]if (catalogHeaderLogo) globalContext.catalogHeaderLogo =..ogHeaderLogo

[MSG]The if statement lacks braces

NoWildcardImports321

[SRC]import java.util.*

[MSG]Wildcard (star) import

UnnecessaryGroovyImport321

[SRC]import java.util.*

NoWildcardImports322

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

UnusedImport326

[SRC]import org.apache.ofbiz.common.CommonWorkers

[MSG]The [org.apache.ofbiz.common.CommonWorkers] import is never referenced

NoWildcardImports327

[SRC]import org.apache.ofbiz.order.shoppingcart.*

[MSG]Wildcard (star) import

NoWildcardImports328

[SRC]import org.apache.ofbiz.webapp.control.*

[MSG]Wildcard (star) import

UnnecessaryGString341

[SRC]globalContext.checkLoginUrl = LoginWorker.makeLoginUrl(r..checkLogin")

[MSG]The String 'checkLogin' can be wrapped in single quotes instead of double quotes

➥ Login.groovy

Rule NamePriorityLine #Source Line / Message
NoWildcardImports321

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

UnusedImport322

[SRC]import org.apache.ofbiz.common.CommonWorkers

[MSG]The [org.apache.ofbiz.common.CommonWorkers] import is never referenced

NoWildcardImports323

[SRC]import org.apache.ofbiz.webapp.control.*

[MSG]Wildcard (star) import

UnnecessaryGString325

[SRC]context.autoUserLogin = session.getAttribute("autoUserLogin")

[MSG]The String 'autoUserLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString326

[SRC]context.autoLogoutUrl = LoginWorker.makeLoginUrl(request..autoLogout")

[MSG]The String 'autoLogout' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]previousParams = session.getAttribute("_PREVIOUS_PARAMS_")

[MSG]The String '_PREVIOUS_PARAMS_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]previousParams = UtilHttp.stripNamedParamsFromQueryStrin.."PASSWORD"])

[MSG]The String 'USERNAME' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]previousParams = UtilHttp.stripNamedParamsFromQueryStrin.."PASSWORD"])

[MSG]The String 'PASSWORD' can be wrapped in single quotes instead of double quotes

UnnecessaryGString331

[SRC]previousParams = "?" + previousParams

[MSG]The String '?' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]previousParams = ""

[MSG]The String '' can be wrapped in single quotes instead of double quotes

➥ Main.groovy

Rule NamePriorityLine #Source Line / Message
NoWildcardImports321

[SRC]import org.apache.ofbiz.product.catalog.*

[MSG]Wildcard (star) import

UnnecessaryGString325

[SRC]request.setAttribute("productCategoryId", promoCat)

[MSG]The String 'productCategoryId' can be wrapped in single quotes instead of double quotes

➥ ProcessPaymentSettings.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod249

[SRC]if ("EXT_OFFLINE".equals(paymentMethodTypeId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.None. Explicit call to EXT_OFFLINE.equals(paymentMethodTypeId) method can be rewritten as (EXT_OFFLINE == (paymentMethodTypeId))

UnnecessaryGroovyImport321

[SRC]import java.util.ArrayList

UnusedImport321

[SRC]import java.util.ArrayList

[MSG]The [java.util.ArrayList] import is never referenced

UnnecessaryGroovyImport322

[SRC]import java.util.HashMap

UnusedImport322

[SRC]import java.util.HashMap

[MSG]The [java.util.HashMap] import is never referenced

UnnecessaryGroovyImport323

[SRC]import java.util.List

UnusedImport323

[SRC]import java.util.List

[MSG]The [java.util.List] import is never referenced

UnnecessaryGroovyImport324

[SRC]import java.util.Map

UnusedImport324

[SRC]import java.util.Map

[MSG]The [java.util.Map] import is never referenced

UnusedImport327

[SRC]import org.apache.ofbiz.base.util.UtilMisc

[MSG]The [org.apache.ofbiz.base.util.UtilMisc] import is never referenced

UnusedImport328

[SRC]import org.apache.ofbiz.entity.Delegator

[MSG]The [org.apache.ofbiz.entity.Delegator] import is never referenced

UnusedImport329

[SRC]import org.apache.ofbiz.entity.GenericValue

[MSG]The [org.apache.ofbiz.entity.GenericValue] import is never referenced

UnusedImport331

[SRC]import org.apache.ofbiz.order.shoppingcart.ShoppingCart

[MSG]The [org.apache.ofbiz.order.shoppingcart.ShoppingCart] import is never referenced

UnusedImport333

[SRC]import org.apache.ofbiz.service.LocalDispatcher

[MSG]The [org.apache.ofbiz.service.LocalDispatcher] import is never referenced

UnnecessaryGString338

[SRC]dispatcher = request.getAttribute("dispatcher")

[MSG]The String 'dispatcher' can be wrapped in single quotes instead of double quotes

UnnecessaryGString339

[SRC]delegator = request.getAttribute("delegator")

[MSG]The String 'delegator' can be wrapped in single quotes instead of double quotes

UnnecessaryGString348

[SRC]paymentMethodId = request.getAttribute("paymentMethodId")

[MSG]The String 'paymentMethodId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]if ("EXT_OFFLINE".equals(paymentMethodTypeId)) {

[MSG]The String 'EXT_OFFLINE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]paymentMethodId = "EXT_OFFLINE"

[MSG]The String 'EXT_OFFLINE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString354

[SRC]isSingleUsePayment = "Y".equalsIgnoreCase(singleUsePayment) ?: false

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]doAppendPayment = "Y".equalsIgnoreCase(appendPayment) ?: false

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]if ("Y".equalsIgnoreCase(addGiftCard)) {

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon366

[SRC]selPaymentMethods = [paymentMethodTypeId : null]

[MSG]The colon for the literal Map entry for key [paymentMethodTypeId] within class org.apache.ofbiz.ecommerce.None is not preceded by a match for regular expression [\S]

UnnecessaryGString383

[SRC]return "error"

[MSG]The String 'error' can be wrapped in single quotes instead of double quotes

UnnecessaryGString385

[SRC]return "success"

[MSG]The String 'success' can be wrapped in single quotes instead of double quotes

Package: org.apache.ofbiz.ecommerce.cart

➥ ShowCart.groovy

Rule NamePriorityLine #Source Line / Message
UnusedImport321

[SRC]import org.apache.ofbiz.base.util.UtilMisc

[MSG]The [org.apache.ofbiz.base.util.UtilMisc] import is never referenced

NoWildcardImports326

[SRC]import org.apache.ofbiz.entity.condition.*

[MSG]Wildcard (star) import

UnnecessaryGString338

[SRC]product = from("Product").where("productId", add_product..).queryOne()

[MSG]The String 'Product' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]product = from("Product").where("productId", add_product..).queryOne()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]allgiftWraps = from("ProductFeature").where("productFeat...queryList()

[MSG]The String 'ProductFeature' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]allgiftWraps = from("ProductFeature").where("productFeat...queryList()

[MSG]The String 'productFeatureTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]allgiftWraps = from("ProductFeature").where("productFeat...queryList()

[MSG]The String 'GIFT_WRAP' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]allgiftWraps = from("ProductFeature").where("productFeat...queryList()

[MSG]The String 'defaultSequenceNum' can be wrapped in single quotes instead of double quotes

UnnecessaryGString348

[SRC]allShoppingLists = from("ShoppingList").where(EntityCond..in.partyId),

[MSG]The String 'ShoppingList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString348

[SRC]allShoppingLists = from("ShoppingList").where(EntityCond..in.partyId),

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]EntityCondition.makeCondition("listName", EntityOperator...queryList()

[MSG]The String 'listName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]EntityCondition.makeCondition("listName", EntityOperator...queryList()

[MSG]The String 'auto-save' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]EntityCondition.makeCondition("listName", EntityOperator...queryList()

[MSG]The String 'listName' can be wrapped in single quotes instead of double quotes

SpaceAfterIf362

[SRC]if(shoppingCartItems) {

[MSG]The if keyword within class org.apache.ofbiz.ecommerce.cart.None is not followed by a single space

UnnecessaryGString372

[SRC]productCategoryMembers = from("ProductCategoryMember").w...queryList()

[MSG]The String 'ProductCategoryMember' can be wrapped in single quotes instead of double quotes

UnnecessaryGString372

[SRC]productCategoryMembers = from("ProductCategoryMember").w...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString375

[SRC]productCategory = productCategoryMember.getRelatedOne("P..ory", false)

[MSG]The String 'ProductCategory' can be wrapped in single quotes instead of double quotes

➥ ShowPromoText.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod235

[SRC]if (promoText && !"N".equals(productPromo.showToCustomer)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.cart.None. Explicit call to N.equals(productPromo.showToCustomer) method can be rewritten as (N == (productPromo.showToCustomer))

InsecureRandom248

[SRC]randomIndex = Math.round(java.lang.Math.random() * (prod..- 1)) as int

[MSG]Using Math.random() is insecure. Use SecureRandom instead

UnusedImport321

[SRC]import org.apache.ofbiz.base.util.UtilMisc

[MSG]The [org.apache.ofbiz.base.util.UtilMisc] import is never referenced

UnnecessaryGString335

[SRC]if (promoText && !"N".equals(productPromo.showToCustomer)) {

[MSG]The String 'N' can be wrapped in single quotes instead of double quotes

UnnecessaryPackageReference348

[SRC]randomIndex = Math.round(java.lang.Math.random() * (prod..- 1)) as int

[MSG]Specifying the package name is not necessary for java.lang.Math

Package: org.apache.ofbiz.ecommerce.catalog

➥ AjaxBreadcrumbs.groovy

Rule NamePriorityLine #Source Line / Message
UnusedImport321

[SRC]import org.apache.ofbiz.product.product.ProductContentWrapper

[MSG]The [org.apache.ofbiz.product.product.ProductContentWrapper] import is never referenced

NoWildcardImports322

[SRC]import org.apache.ofbiz.product.category.*

[MSG]Wildcard (star) import

UnusedImport323

[SRC]import org.apache.ofbiz.base.util.UtilValidate

[MSG]The [org.apache.ofbiz.base.util.UtilValidate] import is never referenced

SpaceAroundOperator326

[SRC]productCategoryId=parameters.category_id

[MSG]The operator "=" within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAroundOperator326

[SRC]productCategoryId=parameters.category_id

[MSG]The operator "=" within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a space or whitespace

SpaceAfterIf327

[SRC]if(parentCategoryStr) {

[MSG]The if keyword within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a single space

SpaceAfterFor331

[SRC]for(path in pathList) {

[MSG]The for keyword within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a single space

UnnecessaryGString333

[SRC]category = from("ProductCategory").where("productCategor..).queryOne()

[MSG]The String 'ProductCategory' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]category = from("ProductCategory").where("productCategor..).queryOne()

[MSG]The String 'productCategoryId' can be wrapped in single quotes instead of double quotes

TrailingWhitespace335

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString337

[SRC]cateMap.title = categoryContentWrapper.get("DESCRIPTION", "html")

[MSG]The String 'DESCRIPTION' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]cateMap.title = categoryContentWrapper.get("DESCRIPTION", "html")

[MSG]The String 'html' can be wrapped in single quotes instead of double quotes

TrailingWhitespace340

[SRC]

[MSG]Line ends with whitespace characters

TrailingWhitespace342

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString348

[SRC]currentCategory = from("ProductCategory").where("product..).queryOne()

[MSG]The String 'ProductCategory' can be wrapped in single quotes instead of double quotes

UnnecessaryGString348

[SRC]currentCategory = from("ProductCategory").where("product..).queryOne()

[MSG]The String 'productCategoryId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]context.currentCategoryName = currentCategoryContentWrap..ME", "html")

[MSG]The String 'CATEGORY_NAME' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]context.currentCategoryName = currentCategoryContentWrap..ME", "html")

[MSG]The String 'html' can be wrapped in single quotes instead of double quotes

UnnecessaryGString351

[SRC]context.currentCategoryDescription = currentCategoryCont..ON", "html")

[MSG]The String 'DESCRIPTION' can be wrapped in single quotes instead of double quotes

UnnecessaryGString351

[SRC]context.currentCategoryDescription = currentCategoryCont..ON", "html")

[MSG]The String 'html' can be wrapped in single quotes instead of double quotes

➥ BestSellingCategory.groovy

Rule NamePriorityLine #Source Line / Message
UnusedImport321

[SRC]import org.apache.ofbiz.base.util.UtilValidate

[MSG]The [org.apache.ofbiz.base.util.UtilValidate] import is never referenced

UnusedImport322

[SRC]import org.apache.ofbiz.base.util.UtilMisc

[MSG]The [org.apache.ofbiz.base.util.UtilMisc] import is never referenced

NoWildcardImports323

[SRC]import org.apache.ofbiz.product.catalog.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.product.category.*

[MSG]Wildcard (star) import

UnnecessaryGString330

[SRC]prodCatalogCategoryList = CatalogWorker.getProdCatalogCa.._BEST_SELL")

[MSG]The String 'PCCT_BEST_SELL' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]productCategoryId = prodCatalogCategory.getString("productCategoryId")

[MSG]The String 'productCategoryId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]childCategoryList = CategoryWorker.getRelatedCategoriesR..oryId, true)

[MSG]The String 'childCategoryList' can be wrapped in single quotes instead of double quotes

➥ LayeredNavigation.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod247

[SRC]if (!parameters.clearSearch || !"N".equals(parameters.clearSearch)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.catalog.None. Explicit call to N.equals(parameters.clearSearch) method can be rewritten as (N == (parameters.clearSearch))

LineLength281

[SRC]thisSubCategoryList.add([productCategoryId: subCategory...entWrapper])

[MSG]The line exceeds 150 characters. The line is 200 characters.

LineLength2111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The line exceeds 150 characters. The line is 276 characters.

LineLength2115

[SRC]priceRangeConstraint = new ProductSearch.ListPriceRangeC..om(request))

[MSG]The line exceeds 150 characters. The line is 168 characters.

LineLength2119

[SRC]priceRangeCount = ProductSearchSession.getCountForListPr.., delegator)

[MSG]The line exceeds 150 characters. The line is 157 characters.

UnusedImport322

[SRC]import org.apache.ofbiz.entity.util.EntityUtil

[MSG]The [org.apache.ofbiz.entity.util.EntityUtil] import is never referenced

CouldBeElvis330

[SRC]if (!searchCategoryId) {

[MSG]Code could use elvis operator: searchCategoryId = searchCategoryId ?: context.productCategoryId

UnnecessaryGString334

[SRC]currentSearchCategory = from("ProductCategory").where("p..).queryOne()

[MSG]The String 'ProductCategory' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]currentSearchCategory = from("ProductCategory").where("p..).queryOne()

[MSG]The String 'productCategoryId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]CategoryWorker.getRelatedCategories(request, "subCategor..ryId, false)

[MSG]The String 'subCategoryList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]subCategoryList = request.getAttribute("subCategoryList")

[MSG]The String 'subCategoryList' can be wrapped in single quotes instead of double quotes

Indentation343

[SRC]context.productCategory = from("ProductCategory").where(..).queryOne()

[MSG]The statement on line 43 in class org.apache.ofbiz.ecommerce.catalog.None is at the incorrect indent level: Expected column 5 but was 4

UnnecessaryGString343

[SRC]context.productCategory = from("ProductCategory").where(..).queryOne()

[MSG]The String 'ProductCategory' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]context.productCategory = from("ProductCategory").where(..).queryOne()

[MSG]The String 'productCategoryId' can be wrapped in single quotes instead of double quotes

Indentation344

[SRC]parameters.SEARCH_CATEGORY_ID = productCategoryId

[MSG]The statement on line 44 in class org.apache.ofbiz.ecommerce.catalog.None is at the incorrect indent level: Expected column 5 but was 4

UnnecessaryGString347

[SRC]if (!parameters.clearSearch || !"N".equals(parameters.clearSearch)) {

[MSG]The String 'N' can be wrapped in single quotes instead of double quotes

SpaceAfterComma351

[SRC]request.getSession().setAttribute("dispatcher",dispatcher)

[MSG]The parameter dispatcher in the call to method setAttribute within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

UnnecessaryGString351

[SRC]request.getSession().setAttribute("dispatcher",dispatcher)

[MSG]The String 'dispatcher' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]productCategoryRollups = from("ProductCategoryRollup").w...queryList()

[MSG]The String 'ProductCategoryRollup' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]productCategoryRollups = from("ProductCategoryRollup").w...queryList()

[MSG]The String 'productCategoryId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString394

[SRC]colors = ProductSearchSession.listCountByFeatureForType(.., delegator)

[MSG]The String 'COLOR' can be wrapped in single quotes instead of double quotes

UnnecessaryGString395

[SRC]colorFeatureType = from("ProductFeatureType").where("pro..).queryOne()

[MSG]The String 'ProductFeatureType' can be wrapped in single quotes instead of double quotes

UnnecessaryGString395

[SRC]colorFeatureType = from("ProductFeatureType").where("pro..).queryOne()

[MSG]The String 'productFeatureTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString395

[SRC]colorFeatureType = from("ProductFeatureType").where("pro..).queryOne()

[MSG]The String 'COLOR' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3100

[SRC]context.showColors=false

[MSG]The operator "=" within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAroundOperator3100

[SRC]context.showColors=false

[MSG]The operator "=" within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a space or whitespace

TrailingWhitespace3102

[SRC]}

[MSG]Line ends with whitespace characters

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '0' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '10' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '10' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '20' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '20' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '30' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '30' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '40' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '40' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '50' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '50' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '60' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '60' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '70' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '70' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '80' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '80' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '90' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '90' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]availablePriceRangeList = [[low: "0", high: "10"], [low:..igh: "100"]]

[MSG]The String '100' can be wrapped in single quotes instead of double quotes

UnnecessaryObjectReferences3140

[SRC]context.searchConstraintStrings = result.searchConstraintStrings

[MSG]The code could be more concise by using a with() or identity() block

➥ MiniProductSummary.groovy

Rule NamePriorityLine #Source Line / Message
IfStatementBraces254

[SRC]if (userLogin) priceParams.partyId = userLogin.partyId

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod259

[SRC]if ("Y".equals(productStore.get("showPricesWithVatTax"))) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.catalog.None. Explicit call to Y.equals(productStore.get(showPricesWithVatTax)) method can be rewritten as (Y == (productStore.get(showPricesWithVatTax)))

LineLength260

[SRC]Map priceMap = runService('calcTaxForDisplay', ["basePri..uctStoreId])

[MSG]The line exceeds 150 characters. The line is 174 characters.

ExplicitCallToEqualsMethod267

[SRC]if ("AGGREGATED".equals(miniProduct.productTypeId) || "A..ctTypeId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.catalog.None. Explicit call to AGGREGATED.equals(miniProduct.productTypeId) method can be rewritten as (AGGREGATED == (miniProduct.productTypeId))

ExplicitCallToEqualsMethod267

[SRC]if ("AGGREGATED".equals(miniProduct.productTypeId) || "A..ctTypeId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.catalog.None. Explicit call to AGGREGATED_SERVICE.equals(miniProduct.productTypeId) method can be rewritten as (AGGREGATED_SERVICE == (miniProduct.productTypeId))

ExplicitCallToEqualsMethod272

[SRC]if ("Y".equals(productStore.get("showPricesWithVatTax"))) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.catalog.None. Explicit call to Y.equals(productStore.get(showPricesWithVatTax)) method can be rewritten as (Y == (productStore.get(showPricesWithVatTax)))

LineLength274

[SRC]Map totalPriceMap = runService('calcTaxForDisplay', ["ba..uctStoreId])

[MSG]The line exceeds 150 characters. The line is 178 characters.

UnnecessaryGroovyImport321

[SRC]import java.math.BigDecimal

UnnecessaryGroovyImport322

[SRC]import java.util.Map

NoWildcardImports324

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports326

[SRC]import org.apache.ofbiz.service.*

[MSG]Wildcard (star) import

NoWildcardImports329

[SRC]import org.apache.ofbiz.product.catalog.*

[MSG]Wildcard (star) import

NoWildcardImports330

[SRC]import org.apache.ofbiz.product.store.*

[MSG]Wildcard (star) import

NoWildcardImports331

[SRC]import org.apache.ofbiz.order.shoppingcart.*

[MSG]Wildcard (star) import

UnnecessaryGString334

[SRC]miniProduct = request.getAttribute("miniProduct")

[MSG]The String 'miniProduct' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]optProductId = request.getAttribute("optProductId")

[MSG]The String 'optProductId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]context.remove("totalPrice")

[MSG]The String 'totalPrice' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]miniProduct = from("Product").where("productId", optProd..).queryOne()

[MSG]The String 'Product' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]miniProduct = from("Product").where("productId", optProd..).queryOne()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon348

[SRC]priceParams = [product : miniProduct,

[MSG]The colon for the literal Map entry for key [product] within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon349

[SRC]prodCatalogId : prodCatalogId,

[MSG]The colon for the literal Map entry for key [prodCatalogId] within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon350

[SRC]webSiteId : webSiteId,

[MSG]The colon for the literal Map entry for key [webSiteId] within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon351

[SRC]currencyUomId : cart.getCurrency(),

[MSG]The colon for the literal Map entry for key [currencyUomId] within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon352

[SRC]autoUserLogin : autoUserLogin,

[MSG]The colon for the literal Map entry for key [autoUserLogin] within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon353

[SRC]productStoreId : productStoreId]

[MSG]The colon for the literal Map entry for key [productStoreId] within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a match for regular expression [\S]

UnnecessaryGString359

[SRC]if ("Y".equals(productStore.get("showPricesWithVatTax"))) {

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString359

[SRC]if ("Y".equals(productStore.get("showPricesWithVatTax"))) {

[MSG]The String 'showPricesWithVatTax' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]Map priceMap = runService('calcTaxForDisplay', ["basePri..uctStoreId])

[MSG]The String 'basePrice' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]Map priceMap = runService('calcTaxForDisplay', ["basePri..uctStoreId])

[MSG]The String 'price' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]Map priceMap = runService('calcTaxForDisplay', ["basePri..uctStoreId])

[MSG]The String 'locale' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]Map priceMap = runService('calcTaxForDisplay', ["basePri..uctStoreId])

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]Map priceMap = runService('calcTaxForDisplay', ["basePri..uctStoreId])

[MSG]The String 'productStoreId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]context.price = priceMap.get("priceWithTax")

[MSG]The String 'priceWithTax' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]context.price = priceResult.get("price")

[MSG]The String 'price' can be wrapped in single quotes instead of double quotes

UnnecessaryGString367

[SRC]if ("AGGREGATED".equals(miniProduct.productTypeId) || "A..ctTypeId)) {

[MSG]The String 'AGGREGATED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString367

[SRC]if ("AGGREGATED".equals(miniProduct.productTypeId) || "A..ctTypeId)) {

[MSG]The String 'AGGREGATED_SERVICE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString372

[SRC]if ("Y".equals(productStore.get("showPricesWithVatTax"))) {

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString372

[SRC]if ("Y".equals(productStore.get("showPricesWithVatTax"))) {

[MSG]The String 'showPricesWithVatTax' can be wrapped in single quotes instead of double quotes

UnnecessaryGString374

[SRC]Map totalPriceMap = runService('calcTaxForDisplay', ["ba..uctStoreId])

[MSG]The String 'basePrice' can be wrapped in single quotes instead of double quotes

UnnecessaryGString374

[SRC]Map totalPriceMap = runService('calcTaxForDisplay', ["ba..uctStoreId])

[MSG]The String 'locale' can be wrapped in single quotes instead of double quotes

UnnecessaryGString374

[SRC]Map totalPriceMap = runService('calcTaxForDisplay', ["ba..uctStoreId])

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString374

[SRC]Map totalPriceMap = runService('calcTaxForDisplay', ["ba..uctStoreId])

[MSG]The String 'productStoreId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString375

[SRC]context.totalPrice = totalPriceMap.get("priceWithTax")

[MSG]The String 'priceWithTax' can be wrapped in single quotes instead of double quotes

UnnecessaryGString385

[SRC]context.miniProdFormName = request.getAttribute("miniProdFormName")

[MSG]The String 'miniProdFormName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString386

[SRC]context.miniProdQuantity = request.getAttribute("miniProdQuantity")

[MSG]The String 'miniProdQuantity' can be wrapped in single quotes instead of double quotes

BlockEndsWithBlankLine391

[MSG]Code block ends with a blank line.

➥ PopularTags.groovy

Rule NamePriorityLine #Source Line / Message
LineLength249

[SRC]productTags = from("ProductKeyword").where("keyword", pr...queryList()

[MSG]The line exceeds 150 characters. The line is 152 characters.

NoDouble268

[SRC]double weight = 0

[MSG]The variable weight in class org.apache.ofbiz.ecommerce.catalog.None is of type double/Double. Prefer using BigDecimal.

NoDouble272

[SRC]double fontSize = minFontSize + ((maxFontSize - minFontSize) * weight)

[MSG]The variable fontSize in class org.apache.ofbiz.ecommerce.catalog.None is of type double/Double. Prefer using BigDecimal.

UnnecessaryGroovyImport321

[SRC]import java.util.List

UnusedImport321

[SRC]import java.util.List

[MSG]The [java.util.List] import is never referenced

NoWildcardImports322

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.entity.condition.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.entity.util.*

[MSG]Wildcard (star) import

UnusedImport325

[SRC]import org.apache.ofbiz.entity.util.EntityUtil

[MSG]The [org.apache.ofbiz.entity.util.EntityUtil] import is never referenced

NoWildcardImports326

[SRC]import org.apache.ofbiz.entity.transaction.*

[MSG]Wildcard (star) import

NoWildcardImports327

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports328

[SRC]import org.apache.ofbiz.base.util.string.*

[MSG]Wildcard (star) import

NoWildcardImports329

[SRC]import org.apache.ofbiz.content.content.*

[MSG]Wildcard (star) import

UnusedImport330

[SRC]import org.apache.commons.lang.StringEscapeUtils

[MSG]The [org.apache.commons.lang.StringEscapeUtils] import is never referenced

UnnecessaryGString333

[SRC]int minFontSize = EntityUtilProperties.getPropertyAsInte..).intValue()

[MSG]The String 'ecommerce' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]int minFontSize = EntityUtilProperties.getPropertyAsInte..).intValue()

[MSG]The String 'tagcloud.min.fontsize' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]int maxFontSize = EntityUtilProperties.getPropertyAsInte..).intValue()

[MSG]The String 'ecommerce' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]int maxFontSize = EntityUtilProperties.getPropertyAsInte..).intValue()

[MSG]The String 'tagcloud.max.fontsize' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]int limitTagCloud = EntityUtilProperties.getPropertyAsIn..).intValue()

[MSG]The String 'ecommerce' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]int limitTagCloud = EntityUtilProperties.getPropertyAsIn..).intValue()

[MSG]The String 'tagcloud.limit' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]productKeywords = select("keyword", "keywordTypeId", "statusId")

[MSG]The String 'keyword' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]productKeywords = select("keyword", "keywordTypeId", "statusId")

[MSG]The String 'keywordTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]productKeywords = select("keyword", "keywordTypeId", "statusId")

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString341

[SRC].from("ProductKeyword")

[MSG]The String 'ProductKeyword' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon342

[SRC].where(keywordTypeId : "KWT_TAG", statusId : "KW_APPROVED")

[MSG]The colon for the literal Map entry for key [keywordTypeId] within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon342

[SRC].where(keywordTypeId : "KWT_TAG", statusId : "KW_APPROVED")

[MSG]The colon for the literal Map entry for key [statusId] within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a match for regular expression [\S]

UnnecessaryGString342

[SRC].where(keywordTypeId : "KWT_TAG", statusId : "KW_APPROVED")

[MSG]The String 'KWT_TAG' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC].where(keywordTypeId : "KWT_TAG", statusId : "KW_APPROVED")

[MSG]The String 'KW_APPROVED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC].orderBy("keyword")

[MSG]The String 'keyword' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]productTags = from("ProductKeyword").where("keyword", pr...queryList()

[MSG]The String 'ProductKeyword' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]productTags = from("ProductKeyword").where("keyword", pr...queryList()

[MSG]The String 'keyword' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]productTags = from("ProductKeyword").where("keyword", pr...queryList()

[MSG]The String 'keywordTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]productTags = from("ProductKeyword").where("keyword", pr...queryList()

[MSG]The String 'KWT_TAG' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]productTags = from("ProductKeyword").where("keyword", pr...queryList()

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]productTags = from("ProductKeyword").where("keyword", pr...queryList()

[MSG]The String 'KW_APPROVED' can be wrapped in single quotes instead of double quotes

SpaceAfterComma359

[SRC]tagList.sort{ a,b -> b.countTag <=> a.countTag }

[MSG]The closure parameter b within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceBeforeOpeningBrace359

[SRC]tagList.sort{ a,b -> b.countTag <=> a.countTag }

[MSG]The opening brace for the closure in class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAfterOpeningBrace381

[SRC]tagCloudList = tagCloudList.sort{it.tag}

[MSG]The opening brace for the closure in class org.apache.ofbiz.ecommerce.catalog.None is not followed by a space or whitespace

SpaceBeforeClosingBrace381

[SRC]tagCloudList = tagCloudList.sort{it.tag}

[MSG]The closing brace for the closure in class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceBeforeOpeningBrace381

[SRC]tagCloudList = tagCloudList.sort{it.tag}

[MSG]The opening brace for the closure in class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

➥ ProductCategories.groovy

Rule NamePriorityLine #Source Line / Message
ParameterName232

[SRC]List fillTree(rootCat ,CatLvl, parentCategoryId) {

[MSG]The parameter named CatLvl in method fillTree of class org.apache.ofbiz.ecommerce.catalog.None does not match [a-z][a-zA-Z0-9]*

IfStatementBraces243

[SRC]if(CatLvl==2)

[MSG]The if statement lacks braces

ElseBlockBraces246

[SRC]else if(CatLvl==1)

[MSG]The else block lacks braces

IfStatementBraces246

[SRC]else if(CatLvl==1)

[MSG]The if statement lacks braces

ElseBlockBraces262

[SRC]if(categoryContentWrapper.get("CATEGORY_NAME", "html").toString())

[MSG]The else block lacks braces

IfStatementBraces262

[SRC]if(categoryContentWrapper.get("CATEGORY_NAME", "html").toString())

[MSG]The if statement lacks braces

ElseBlockBraces267

[SRC]if(categoryContentWrapper.get("DESCRIPTION", "html").toString())

[MSG]The else block lacks braces

IfStatementBraces267

[SRC]if(categoryContentWrapper.get("DESCRIPTION", "html").toString())

[MSG]The if statement lacks braces

LineLength283

[SRC]CategoryWorker.getRelatedCategories(request, "topLevelLi..est)), true)

[MSG]The line exceeds 150 characters. The line is 158 characters.

NoWildcardImports327

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports328

[SRC]import org.apache.ofbiz.product.catalog.*

[MSG]Wildcard (star) import

NoWildcardImports329

[SRC]import org.apache.ofbiz.product.category.*

[MSG]Wildcard (star) import

NoWildcardImports330

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

MethodParameterTypeRequired332

[SRC]List fillTree(rootCat ,CatLvl, parentCategoryId) {

[MSG]"rootCat" parameter of "fillTree" method is dynamically typed

MethodParameterTypeRequired332

[SRC]List fillTree(rootCat ,CatLvl, parentCategoryId) {

[MSG]"CatLvl" parameter of "fillTree" method is dynamically typed

MethodParameterTypeRequired332

[SRC]List fillTree(rootCat ,CatLvl, parentCategoryId) {

[MSG]"parentCategoryId" parameter of "fillTree" method is dynamically typed

NoDef332

[SRC]List fillTree(rootCat ,CatLvl, parentCategoryId) {

[MSG]def for method parameter type should not be used

NoDef332

[SRC]List fillTree(rootCat ,CatLvl, parentCategoryId) {

[MSG]def for method parameter type should not be used

NoDef332

[SRC]List fillTree(rootCat ,CatLvl, parentCategoryId) {

[MSG]def for method parameter type should not be used

SpaceAfterIf333

[SRC]if(rootCat) {

[MSG]The if keyword within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a single space

SpaceBeforeOpeningBrace334

[SRC]rootCat.sort{ it.productCategoryId }

[MSG]The opening brace for the closure in class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

NoDef335

[SRC]def listTree = []

[MSG]def for declaration should not be used

VariableTypeRequired335

[SRC]def listTree = []

[MSG]The type is not specified for variable "listTree"

SpaceAfterFor336

[SRC]for(root in rootCat) {

[MSG]The for keyword within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a single space

UnnecessaryGString337

[SRC]preCatChilds = from("ProductCategoryRollup").where("pare...queryList()

[MSG]The String 'ProductCategoryRollup' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]preCatChilds = from("ProductCategoryRollup").where("pare...queryList()

[MSG]The String 'parentProductCategoryId' can be wrapped in single quotes instead of double quotes

SpaceAfterComma338

[SRC]catChilds = EntityUtil.getRelated("CurrentProductCategor..hilds,false)

[MSG]The parameter null in the call to method getRelated within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAfterComma338

[SRC]catChilds = EntityUtil.getRelated("CurrentProductCategor..hilds,false)

[MSG]The parameter preCatChilds in the call to method getRelated within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAfterComma338

[SRC]catChilds = EntityUtil.getRelated("CurrentProductCategor..hilds,false)

[MSG]The parameter false in the call to method getRelated within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

UnnecessaryGString338

[SRC]catChilds = EntityUtil.getRelated("CurrentProductCategor..hilds,false)

[MSG]The String 'CurrentProductCategory' can be wrapped in single quotes instead of double quotes

NoDef339

[SRC]def childList = []

[MSG]def for declaration should not be used

VariableTypeRequired339

[SRC]def childList = []

[MSG]The type is not specified for variable "childList"

TrailingWhitespace340

[SRC]

[MSG]Line ends with whitespace characters

SpaceAfterIf342

[SRC]if(catChilds) {

[MSG]The if keyword within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a single space

SpaceAfterIf343

[SRC]if(CatLvl==2)

[MSG]The if keyword within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a single space

SpaceAroundOperator343

[SRC]if(CatLvl==2)

[MSG]The operator "==" within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAroundOperator343

[SRC]if(CatLvl==2)

[MSG]The operator "==" within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a space or whitespace

SpaceAfterComma344

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The parameter (CatLvl + 1) in the call to method fillTree within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAroundOperator344

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The operator "+" within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAroundOperator344

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The operator "+" within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a space or whitespace

SpaceAroundOperator344

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The operator "+" within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAroundOperator344

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The operator "+" within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a space or whitespace

SpaceAroundOperator344

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The operator "+" within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAroundOperator344

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The operator "+" within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a space or whitespace

UnnecessaryGString344

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The String '/' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The String '' can be wrapped in single quotes instead of double quotes

SpaceAfterIf346

[SRC]else if(CatLvl==1)

[MSG]The if keyword within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a single space

SpaceAroundOperator346

[SRC]else if(CatLvl==1)

[MSG]The operator "==" within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAroundOperator346

[SRC]else if(CatLvl==1)

[MSG]The operator "==" within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a space or whitespace

SpaceAfterComma347

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The parameter (CatLvl + 1) in the call to method fillTree within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAroundOperator347

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The operator "+" within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAroundOperator347

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The operator "+" within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a space or whitespace

SpaceAroundOperator347

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The operator "+" within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAroundOperator347

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The operator "+" within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a space or whitespace

UnnecessaryGString347

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The String '/' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The String '' can be wrapped in single quotes instead of double quotes

SpaceAfterComma349

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The parameter (CatLvl + 1) in the call to method fillTree within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAroundOperator349

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The operator "+" within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAroundOperator349

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The operator "+" within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a space or whitespace

SpaceAroundOperator349

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The operator "+" within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAroundOperator349

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The operator "+" within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a space or whitespace

SpaceAroundOperator349

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The operator "+" within class org.apache.ofbiz.ecommerce.catalog.None is not preceded by a space or whitespace

SpaceAroundOperator349

[SRC]childList = fillTree(catChilds,CatLvl+1, parentCategoryI..tCategoryId)

[MSG]The operator "+" within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a space or whitespace

TrailingWhitespace351

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString352

[SRC]productsInCat = from("ProductCategoryAndMember").where(...queryList()

[MSG]The String 'ProductCategoryAndMember' can be wrapped in single quotes instead of double quotes

UnnecessaryGString352

[SRC]productsInCat = from("ProductCategoryAndMember").where(...queryList()

[MSG]The String 'productCategoryId' can be wrapped in single quotes instead of double quotes

TrailingWhitespace353

[SRC]

[MSG]Line ends with whitespace characters

SpaceAfterIf355

[SRC]if(productsInCat || childList) {

[MSG]The if keyword within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a single space

NoDef356

[SRC]def rootMap = [:]

[MSG]def for declaration should not be used

VariableTypeRequired356

[SRC]def rootMap = [:]

[MSG]The type is not specified for variable "rootMap"

UnnecessaryGString357

[SRC]category = from("ProductCategory").where("productCategor..).queryOne()

[MSG]The String 'ProductCategory' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]category = from("ProductCategory").where("productCategor..).queryOne()

[MSG]The String 'productCategoryId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString359

[SRC]context.title = categoryContentWrapper.get("CATEGORY_NAME", "html")

[MSG]The String 'CATEGORY_NAME' can be wrapped in single quotes instead of double quotes

UnnecessaryGString359

[SRC]context.title = categoryContentWrapper.get("CATEGORY_NAME", "html")

[MSG]The String 'html' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]categoryDescription = categoryContentWrapper.get("DESCRI..ON", "html")

[MSG]The String 'DESCRIPTION' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]categoryDescription = categoryContentWrapper.get("DESCRI..ON", "html")

[MSG]The String 'html' can be wrapped in single quotes instead of double quotes

TrailingWhitespace361

[SRC]

[MSG]Line ends with whitespace characters

SpaceAfterIf362

[SRC]if(categoryContentWrapper.get("CATEGORY_NAME", "html").toString())

[MSG]The if keyword within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a single space

UnnecessaryGString362

[SRC]if(categoryContentWrapper.get("CATEGORY_NAME", "html").toString())

[MSG]The String 'CATEGORY_NAME' can be wrapped in single quotes instead of double quotes

UnnecessaryGString362

[SRC]if(categoryContentWrapper.get("CATEGORY_NAME", "html").toString())

[MSG]The String 'html' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]rootMap["categoryName"] = categoryContentWrapper.get("CA..ME", "html")

[MSG]The String 'categoryName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]rootMap["categoryName"] = categoryContentWrapper.get("CA..ME", "html")

[MSG]The String 'CATEGORY_NAME' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]rootMap["categoryName"] = categoryContentWrapper.get("CA..ME", "html")

[MSG]The String 'html' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]rootMap["categoryName"] = root.categoryName

[MSG]The String 'categoryName' can be wrapped in single quotes instead of double quotes

TrailingWhitespace366

[SRC]

[MSG]Line ends with whitespace characters

SpaceAfterIf367

[SRC]if(categoryContentWrapper.get("DESCRIPTION", "html").toString())

[MSG]The if keyword within class org.apache.ofbiz.ecommerce.catalog.None is not followed by a single space

UnnecessaryGString367

[SRC]if(categoryContentWrapper.get("DESCRIPTION", "html").toString())

[MSG]The String 'DESCRIPTION' can be wrapped in single quotes instead of double quotes

UnnecessaryGString367

[SRC]if(categoryContentWrapper.get("DESCRIPTION", "html").toString())

[MSG]The String 'html' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]rootMap["categoryDescription"] = categoryContentWrapper...ON", "html")

[MSG]The String 'categoryDescription' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]rootMap["categoryDescription"] = categoryContentWrapper...ON", "html")

[MSG]The String 'DESCRIPTION' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]rootMap["categoryDescription"] = categoryContentWrapper...ON", "html")

[MSG]The String 'html' can be wrapped in single quotes instead of double quotes

UnnecessaryGString370

[SRC]rootMap["categoryDescription"] = root.description

[MSG]The String 'categoryDescription' can be wrapped in single quotes instead of double quotes

TrailingWhitespace371

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString372

[SRC]rootMap["productCategoryId"] = root.productCategoryId

[MSG]The String 'productCategoryId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString373

[SRC]rootMap["parentCategoryId"] = parentCategoryId

[MSG]The String 'parentCategoryId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString374

[SRC]rootMap["child"] = childList

[MSG]The String 'child' can be wrapped in single quotes instead of double quotes

UnnecessaryGString383

[SRC]CategoryWorker.getRelatedCategories(request, "topLevelLi..est)), true)

[MSG]The String 'topLevelList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString384

[SRC]curCategoryId = parameters.category_id ?: parameters.CATEGORY_ID ?: ""

[MSG]The String '' can be wrapped in single quotes instead of double quotes

UnnecessaryGString385

[SRC]request.setAttribute("curCategoryId", curCategoryId)

[MSG]The String 'curCategoryId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString388

[SRC]categoryList = request.getAttribute("topLevelList")

[MSG]The String 'topLevelList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString393

[SRC]completedTree = fillTree(categoryList, 1, "")

[MSG]The String '' can be wrapped in single quotes instead of double quotes

Package: org.apache.ofbiz.ecommerce.content

➥ AdvancedSearchPrep.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod230

[SRC]if (!"AND".equals(searchOperator) && !"OR".equals(searchOperator)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.content.None. Explicit call to AND.equals(searchOperator) method can be rewritten as (AND == (searchOperator))

ExplicitCallToEqualsMethod230

[SRC]if (!"AND".equals(searchOperator) && !"OR".equals(searchOperator)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.content.None. Explicit call to OR.equals(searchOperator) method can be rewritten as (OR == (searchOperator))

NoWildcardImports321

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports322

[SRC]import org.apache.ofbiz.product.catalog.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.product.feature.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.product.product.*

[MSG]Wildcard (star) import

UnnecessaryGString330

[SRC]if (!"AND".equals(searchOperator) && !"OR".equals(searchOperator)) {

[MSG]The String 'AND' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]if (!"AND".equals(searchOperator) && !"OR".equals(searchOperator)) {

[MSG]The String 'OR' can be wrapped in single quotes instead of double quotes

Indentation331

[SRC]searchOperator = "OR"

[MSG]The statement on line 31 in class org.apache.ofbiz.ecommerce.content.None is at the incorrect indent level: Expected column 5 but was 3

UnnecessaryGString331

[SRC]searchOperator = "OR"

[MSG]The String 'OR' can be wrapped in single quotes instead of double quotes

➥ Mrv.groovy

Rule NamePriorityLine #Source Line / Message
EmptyElseBlock265

[SRC]} else {

[MSG]The else block is empty

UnnecessaryGroovyImport321

[SRC]import java.util.ArrayList

UnusedImport321

[SRC]import java.util.ArrayList

[MSG]The [java.util.ArrayList] import is never referenced

UnnecessaryGroovyImport322

[SRC]import java.util.Collection

UnusedImport322

[SRC]import java.util.Collection

[MSG]The [java.util.Collection] import is never referenced

UnnecessaryGroovyImport323

[SRC]import java.util.HashMap

UnusedImport323

[SRC]import java.util.HashMap

[MSG]The [java.util.HashMap] import is never referenced

UnnecessaryGroovyImport324

[SRC]import java.util.Iterator

UnusedImport324

[SRC]import java.util.Iterator

[MSG]The [java.util.Iterator] import is never referenced

UnnecessaryGroovyImport325

[SRC]import java.util.LinkedList

UnusedImport325

[SRC]import java.util.LinkedList

[MSG]The [java.util.LinkedList] import is never referenced

UnnecessaryGroovyImport326

[SRC]import java.util.List

UnusedImport326

[SRC]import java.util.List

[MSG]The [java.util.List] import is never referenced

UnnecessaryGroovyImport327

[SRC]import java.util.Map

UnusedImport327

[SRC]import java.util.Map

[MSG]The [java.util.Map] import is never referenced

UnnecessaryGroovyImport328

[SRC]import java.util.Set

UnusedImport328

[SRC]import java.util.Set

[MSG]The [java.util.Set] import is never referenced

UnnecessaryGroovyImport329

[SRC]import java.util.TreeSet

UnusedImport329

[SRC]import java.util.TreeSet

[MSG]The [java.util.TreeSet] import is never referenced

NoWildcardImports331

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports332

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports333

[SRC]import org.apache.ofbiz.security.*

[MSG]Wildcard (star) import

NoWildcardImports334

[SRC]import org.apache.ofbiz.service.*

[MSG]Wildcard (star) import

NoWildcardImports335

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

NoWildcardImports338

[SRC]import javax.servlet.*

[MSG]Wildcard (star) import

NoWildcardImports339

[SRC]import javax.servlet.http.*

[MSG]Wildcard (star) import

UnnecessaryGString341

[SRC]entityName = "ContentDataResourceView"

[MSG]The String 'ContentDataResourceView' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC]lookupCaches = session.getAttribute("lookupCaches")

[MSG]The String 'lookupCaches' can be wrapped in single quotes instead of double quotes

UnnecessaryGString346

[SRC]session.setAttribute("lookupCaches", lookupCaches)

[MSG]The String 'lookupCaches' can be wrapped in single quotes instead of double quotes

UnnecessaryGString371

[SRC]context.put("mrvList", mrvList)

[MSG]The String 'mrvList' can be wrapped in single quotes instead of double quotes

➥ Search.groovy

Rule NamePriorityLine #Source Line / Message
ReturnNullFromCatchBlock256

[SRC]return

[MSG]Do not return null from a catch block

ExplicitCallToEqualsMethod274

[SRC]if ("any".equals(paramMap.anyOrAll)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.content.None. Explicit call to any.equals(paramMap.anyOrAll) method can be rewritten as (any == (paramMap.anyOrAll))

UnnecessaryToString289

[SRC]logInfo("in search searchFeature3, combQuery:" + combQuery.toString())

[MSG]Calling toString() on [combQuery] in class org.apache.ofbiz.ecommerce.content.None is unnecessary

UnusedImport327

[SRC]import org.apache.ofbiz.base.util.Debug

[MSG]The [org.apache.ofbiz.base.util.Debug] import is never referenced

NoWildcardImports331

[SRC]import org.apache.lucene.search.*

[MSG]Wildcard (star) import

UnnecessaryGString340

[SRC]siteId = paramMap.siteId ?: "WebStoreCONTENT"

[MSG]The String 'WebStoreCONTENT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]Directory directory = FSDirectory.open(new File(SearchWo..)).toPath())

[MSG]The String 'content' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]context.errorMessageList.add(UtilProperties.getMessage("..d", locale))

[MSG]The String 'ContentErrorUiLabels' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]context.errorMessageList.add(UtilProperties.getMessage("..d", locale))

[MSG]The String 'ContentSearchNotIndexed' can be wrapped in single quotes instead of double quotes

UnnecessaryGString359

[SRC]termQuery = new TermQuery(new Term("site", siteId.toString()))

[MSG]The String 'site' can be wrapped in single quotes instead of double quotes

UnnecessaryGString366

[SRC]QueryParser parser = new QueryParser("content", analyzer)

[MSG]The String 'content' can be wrapped in single quotes instead of double quotes

UnnecessaryGString374

[SRC]if ("any".equals(paramMap.anyOrAll)) {

[MSG]The String 'any' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]termQuery = new TermQuery(new Term("feature", value))

[MSG]The String 'feature' can be wrapped in single quotes instead of double quotes

UnnecessaryGString389

[SRC]logInfo("in search searchFeature3, combQuery:" + combQuery.toString())

[MSG]The String 'in search searchFeature3, combQuery:' can be wrapped in single quotes instead of double quotes

UnnecessaryGString393

[SRC]logInfo("in search, hits:" + collector.getTotalHits())

[MSG]The String 'in search, hits:' can be wrapped in single quotes instead of double quotes

UnnecessaryGString399

[SRC]contentId = doc.get("contentId")

[MSG]The String 'contentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3100

[SRC]content = from("Content").where("contentId", contentId)...).queryOne()

[MSG]The String 'Content' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3100

[SRC]content = from("Content").where("contentId", contentId)...).queryOne()

[MSG]The String 'contentId' can be wrapped in single quotes instead of double quotes

Package: org.apache.ofbiz.ecommerce.customer

➥ ChangePassword.groovy

Rule NamePriorityLine #Source Line / Message
IfStatementBraces233

[SRC]if (!tryEntity) userLoginData = UtilHttp.getParameterMap(request)

[MSG]The if statement lacks braces

IfStatementBraces234

[SRC]if (!userLoginData) userLoginData = [:]

[MSG]The if statement lacks braces

UnnecessaryGroovyImport321

[SRC]import java.util.HashMap

UnusedImport321

[SRC]import java.util.HashMap

[MSG]The [java.util.HashMap] import is never referenced

UnnecessaryGString330

[SRC]donePage = parameters.DONE_PAGE ?: "viewprofile"

[MSG]The String 'viewprofile' can be wrapped in single quotes instead of double quotes

CouldBeElvis334

[SRC]if (!userLoginData) userLoginData = [:]

[MSG]Code could use elvis operator: userLoginData = userLoginData ?: [:]

➥ ContactList.groovy

Rule NamePriorityLine #Source Line / Message
LineLength257

[SRC]partyAndContactMechList = from("PartyAndContactMech").wh...queryList()

[MSG]The line exceeds 150 characters. The line is 169 characters.

NoWildcardImports321

[SRC]import java.lang.*

[MSG]Wildcard (star) import

UnnecessaryGroovyImport321

[SRC]import java.lang.*

NoWildcardImports322

[SRC]import java.util.*

[MSG]Wildcard (star) import

UnnecessaryGroovyImport322

[SRC]import java.util.*

NoWildcardImports323

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.entity.util.*

[MSG]Wildcard (star) import

NoWildcardImports326

[SRC]import org.apache.ofbiz.entity.condition.*

[MSG]Wildcard (star) import

UnusedImport327

[SRC]import org.apache.ofbiz.party.contact.ContactMechWorker

[MSG]The [org.apache.ofbiz.party.contact.ContactMechWorker] import is never referenced

UnusedImport328

[SRC]import org.apache.ofbiz.product.store.ProductStoreWorker

[MSG]The [org.apache.ofbiz.product.store.ProductStoreWorker] import is never referenced

UnusedImport330

[SRC]import org.apache.ofbiz.accounting.payment.PaymentWorker

[MSG]The [org.apache.ofbiz.accounting.payment.PaymentWorker] import is never referenced

UnnecessaryGString338

[SRC]exprList.add(EntityCondition.makeCondition("webSiteId", .. webSiteId))

[MSG]The String 'webSiteId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString339

[SRC]exprListThruDate.add(EntityCondition.makeCondition("thru..UALS, null))

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]exprListThruDate.add(EntityCondition.makeCondition("thru..imestamp()))

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]webSiteContactList = from("WebSiteContactList").where(ex...queryList()

[MSG]The String 'WebSiteContactList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]contactList = webSiteContactList.getRelatedOne("ContactList", false)

[MSG]The String 'ContactList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString348

[SRC]contactListType = contactList.getRelatedOne("ContactListType", false)

[MSG]The String 'ContactListType' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]partyAndContactMechList = from("PartyAndContactMech").wh...queryList()

[MSG]The String 'PartyAndContactMech' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]partyAndContactMechList = from("PartyAndContactMech").wh...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]partyAndContactMechList = from("PartyAndContactMech").wh...queryList()

[MSG]The String 'contactMechTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]partyAndContactMechList = from("PartyAndContactMech").wh...queryList()

[MSG]The String 'EMAIL_ADDRESS' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]partyAndContactMechList = from("PartyAndContactMech").wh...queryList()

[MSG]The String '-fromDate' can be wrapped in single quotes instead of double quotes

➥ CustomerReviews.groovy

Rule NamePriorityLine #Source Line / Message
UnusedImport321

[SRC]import org.apache.ofbiz.entity.condition.EntityOperator

[MSG]The [org.apache.ofbiz.entity.condition.EntityOperator] import is never referenced

UnusedImport322

[SRC]import org.apache.ofbiz.entity.condition.EntityCondition

[MSG]The [org.apache.ofbiz.entity.condition.EntityCondition] import is never referenced

Indentation326

[SRC]reviews = from("ProductReview").where("userLoginId", use...queryList()

[MSG]The statement on line 26 in class org.apache.ofbiz.ecommerce.customer.None is at the incorrect indent level: Expected column 5 but was 3

UnnecessaryGString326

[SRC]reviews = from("ProductReview").where("userLoginId", use...queryList()

[MSG]The String 'ProductReview' can be wrapped in single quotes instead of double quotes

UnnecessaryGString326

[SRC]reviews = from("ProductReview").where("userLoginId", use...queryList()

[MSG]The String 'userLoginId' can be wrapped in single quotes instead of double quotes

Indentation328

[SRC]context.reviews = reviews

[MSG]The statement on line 28 in class org.apache.ofbiz.ecommerce.customer.None is at the incorrect indent level: Expected column 5 but was 3

➥ CustomerSurvey.groovy

Rule NamePriorityLine #Source Line / Message
NoWildcardImports321

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

UnusedImport322

[SRC]import org.apache.ofbiz.entity.Delegator

[MSG]The [org.apache.ofbiz.entity.Delegator] import is never referenced

UnusedImport323

[SRC]import org.apache.ofbiz.entity.GenericValue

[MSG]The [org.apache.ofbiz.entity.GenericValue] import is never referenced

UnnecessaryGString331

[SRC]surveyAppl = from("ProductStoreSurveyAppl").where("produ..).queryOne()

[MSG]The String 'ProductStoreSurveyAppl' can be wrapped in single quotes instead of double quotes

UnnecessaryGString331

[SRC]surveyAppl = from("ProductStoreSurveyAppl").where("produ..).queryOne()

[MSG]The String 'productStoreSurveyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]survey = surveyAppl.getRelatedOne("Survey", false)

[MSG]The String 'Survey' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon337

[SRC]paramMap = [productStoreSurveyId : productStoreSurveyId]

[MSG]The colon for the literal Map entry for key [productStoreSurveyId] within class org.apache.ofbiz.ecommerce.customer.None is not preceded by a match for regular expression [\S]

➥ EditBillingAddress.groovy

Rule NamePriorityLine #Source Line / Message
LineLength250

[SRC]paymentMethod = from("PaymentMethod").where("partyId", p..queryFirst()

[MSG]The line exceeds 150 characters. The line is 163 characters.

ExplicitCallToEqualsMethod263

[SRC]if (billToContactMechId && billToContactMechId.equals(sh..ctMechId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.customer.None. Explicit call to billToContactMechId.equals(shipToContactMechId) method can be rewritten as (billToContactMechId == (shipToContactMechId))

UnusedImport323

[SRC]import org.apache.ofbiz.entity.condition.EntityCondition

[MSG]The [org.apache.ofbiz.entity.condition.EntityCondition] import is never referenced

UnnecessaryGString326

[SRC]party = userLogin.getRelatedOne("Party", false)

[MSG]The String 'Party' can be wrapped in single quotes instead of double quotes

UnnecessaryGString327

[SRC]contactMech = EntityUtil.getFirst(ContactHelper.getConta..SS", false))

[MSG]The String 'BILLING_LOCATION' can be wrapped in single quotes instead of double quotes

UnnecessaryGString327

[SRC]contactMech = EntityUtil.getFirst(ContactHelper.getConta..SS", false))

[MSG]The String 'POSTAL_ADDRESS' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]postalAddress = contactMech.getRelatedOne("PostalAddress", false)

[MSG]The String 'PostalAddress' can be wrapped in single quotes instead of double quotes

UnnecessaryObjectReferences339

[SRC]context.billToCountryGeoId = postalAddress.countryGeoId

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryGString340

[SRC]billToStateProvinceGeo = from("Geo").where("geoId", post..).queryOne()

[MSG]The String 'Geo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]billToStateProvinceGeo = from("Geo").where("geoId", post..).queryOne()

[MSG]The String 'geoId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]billToCountryProvinceGeo = from("Geo").where("geoId", po..).queryOne()

[MSG]The String 'Geo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]billToCountryProvinceGeo = from("Geo").where("geoId", po..).queryOne()

[MSG]The String 'geoId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]paymentMethod = from("PaymentMethod").where("partyId", p..queryFirst()

[MSG]The String 'PaymentMethod' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]paymentMethod = from("PaymentMethod").where("partyId", p..queryFirst()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]paymentMethod = from("PaymentMethod").where("partyId", p..queryFirst()

[MSG]The String 'paymentMethodTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]paymentMethod = from("PaymentMethod").where("partyId", p..queryFirst()

[MSG]The String 'CREDIT_CARD' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]paymentMethod = from("PaymentMethod").where("partyId", p..queryFirst()

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString352

[SRC]creditCard = paymentMethod.getRelatedOne("CreditCard", false)

[MSG]The String 'CreditCard' can be wrapped in single quotes instead of double quotes

UnnecessaryGString353

[SRC]context.paymentMethodTypeId = "CREDIT_CARD"

[MSG]The String 'CREDIT_CARD' can be wrapped in single quotes instead of double quotes

UnnecessaryGString364

[SRC]context.useShippingAddressForBilling = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString369

[SRC]billToContactMechList = ContactHelper.getContactMech(par..BER", false)

[MSG]The String 'PHONE_BILLING' can be wrapped in single quotes instead of double quotes

UnnecessaryGString369

[SRC]billToContactMechList = ContactHelper.getContactMech(par..BER", false)

[MSG]The String 'TELECOM_NUMBER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString371

[SRC]billToTelecomNumber = (EntityUtil.getFirst(billToContact..ber", false)

[MSG]The String 'TelecomNumber' can be wrapped in single quotes instead of double quotes

UnnecessaryGString372

[SRC]pcm = EntityUtil.getFirst(billToTelecomNumber.getRelated..ull, false))

[MSG]The String 'PartyContactMech' can be wrapped in single quotes instead of double quotes

UnnecessaryGString377

[SRC]billToFaxNumberList = ContactHelper.getContactMech(party..BER", false)

[MSG]The String 'FAX_BILLING' can be wrapped in single quotes instead of double quotes

UnnecessaryGString377

[SRC]billToFaxNumberList = ContactHelper.getContactMech(party..BER", false)

[MSG]The String 'TELECOM_NUMBER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString379

[SRC]billToFaxNumber = (EntityUtil.getFirst(billToFaxNumberLi..ber", false)

[MSG]The String 'TelecomNumber' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]faxPartyContactMech = EntityUtil.getFirst(billToFaxNumbe..ull, false))

[MSG]The String 'PartyContactMech' can be wrapped in single quotes instead of double quotes

➥ EditContactMech.groovy

Rule NamePriorityLine #Source Line / Message
IfStatementBraces242

[SRC]if (preContactMechTypeId) context.preContactMechTypeId =..ctMechTypeId

[MSG]The if statement lacks braces

IfStatementBraces245

[SRC]if (paymentMethodId) context.paymentMethodId = paymentMethodId

[MSG]The if statement lacks braces

IfStatementBraces261

[SRC]if (!tryEntity) contactMechData = parameters

[MSG]The if statement lacks braces

IfStatementBraces262

[SRC]if (!contactMechData) contactMechData = [:]

[MSG]The if statement lacks braces

IfStatementBraces263

[SRC]if (contactMechData) context.contactMechData = contactMechData

[MSG]The if statement lacks braces

IfStatementBraces266

[SRC]if (!tryEntity) partyContactMechData = parameters

[MSG]The if statement lacks braces

IfStatementBraces267

[SRC]if (!partyContactMechData) partyContactMechData = [:]

[MSG]The if statement lacks braces

IfStatementBraces268

[SRC]if (partyContactMechData) context.partyContactMechData =..tactMechData

[MSG]The if statement lacks braces

IfStatementBraces271

[SRC]if (!tryEntity) postalAddressData = parameters

[MSG]The if statement lacks braces

IfStatementBraces272

[SRC]if (!postalAddressData) postalAddressData = [:]

[MSG]The if statement lacks braces

IfStatementBraces273

[SRC]if (postalAddressData) context.postalAddressData = postalAddressData

[MSG]The if statement lacks braces

IfStatementBraces276

[SRC]if (!tryEntity) telecomNumberData = parameters

[MSG]The if statement lacks braces

IfStatementBraces277

[SRC]if (!telecomNumberData) telecomNumberData = [:]

[MSG]The if statement lacks braces

IfStatementBraces278

[SRC]if (telecomNumberData) context.telecomNumberData = telecomNumberData

[MSG]The if statement lacks braces

UnnecessaryGroovyImport321

[SRC]import java.util.HashMap

UnusedImport321

[SRC]import java.util.HashMap

[MSG]The [java.util.HashMap] import is never referenced

UnusedImport323

[SRC]import org.apache.ofbiz.base.util.UtilHttp

[MSG]The [org.apache.ofbiz.base.util.UtilHttp] import is never referenced

UnusedImport324

[SRC]import org.apache.ofbiz.base.util.UtilMisc

[MSG]The [org.apache.ofbiz.base.util.UtilMisc] import is never referenced

UnnecessaryGString335

[SRC]if (!security.hasEntityPermission("PARTYMGR", "_VIEW", s..ntactMech) {

[MSG]The String 'PARTYMGR' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]if (!security.hasEntityPermission("PARTYMGR", "_VIEW", s..ntactMech) {

[MSG]The String '_VIEW' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]contactMechPurposeType = from("ContactMechPurposeType")...).queryOne()

[MSG]The String 'ContactMechPurposeType' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]contactMechPurposeType = from("ContactMechPurposeType")...).queryOne()

[MSG]The String 'contactMechPurposeTypeId' can be wrapped in single quotes instead of double quotes

CouldBeElvis362

[SRC]if (!contactMechData) contactMechData = [:]

[MSG]Code could use elvis operator: contactMechData = contactMechData ?: [:]

CouldBeElvis367

[SRC]if (!partyContactMechData) partyContactMechData = [:]

[MSG]Code could use elvis operator: partyContactMechData = partyContactMechData ?: [:]

CouldBeElvis372

[SRC]if (!postalAddressData) postalAddressData = [:]

[MSG]Code could use elvis operator: postalAddressData = postalAddressData ?: [:]

CouldBeElvis377

[SRC]if (!telecomNumberData) telecomNumberData = [:]

[MSG]Code could use elvis operator: telecomNumberData = telecomNumberData ?: [:]

UnnecessaryGString382

[SRC]geoValue = from("Geo").where("geoId", parameters.country..).queryOne()

[MSG]The String 'Geo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString382

[SRC]geoValue = from("Geo").where("geoId", parameters.country..).queryOne()

[MSG]The String 'geoId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString387

[SRC]geoValue = from("Geo").where("geoId", postalAddressData...).queryOne()

[MSG]The String 'Geo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString387

[SRC]geoValue = from("Geo").where("geoId", postalAddressData...).queryOne()

[MSG]The String 'geoId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString394

[SRC]geoValue = from("Geo").where("geoId", parameters.statePr..).queryOne()

[MSG]The String 'Geo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString394

[SRC]geoValue = from("Geo").where("geoId", parameters.statePr..).queryOne()

[MSG]The String 'geoId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString399

[SRC]geoValue = from("Geo").where("geoId", postalAddressData...).queryOne()

[MSG]The String 'Geo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString399

[SRC]geoValue = from("Geo").where("geoId", postalAddressData...).queryOne()

[MSG]The String 'geoId' can be wrapped in single quotes instead of double quotes

➥ EditEmailAndTelecomNumber.groovy

Rule NamePriorityLine #Source Line / Message
LineLength235

[SRC]partyContactMech = from("PartyContactMech").where("party..queryFirst()

[MSG]The line exceeds 150 characters. The line is 155 characters.

UnnecessaryGString325

[SRC]party = userLogin.getRelatedOne("Party", false)

[MSG]The String 'Party' can be wrapped in single quotes instead of double quotes

UnnecessaryGString327

[SRC]contactMech = EntityUtil.getFirst(ContactHelper.getConta..SS", false))

[MSG]The String 'PRIMARY_EMAIL' can be wrapped in single quotes instead of double quotes

UnnecessaryGString327

[SRC]contactMech = EntityUtil.getFirst(ContactHelper.getConta..SS", false))

[MSG]The String 'EMAIL_ADDRESS' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]contactMech = EntityUtil.getFirst(ContactHelper.getConta..ER", false))

[MSG]The String 'PRIMARY_PHONE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]contactMech = EntityUtil.getFirst(ContactHelper.getConta..ER", false))

[MSG]The String 'TELECOM_NUMBER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]partyContactMech = from("PartyContactMech").where("party..queryFirst()

[MSG]The String 'PartyContactMech' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]partyContactMech = from("PartyContactMech").where("party..queryFirst()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]partyContactMech = from("PartyContactMech").where("party..queryFirst()

[MSG]The String 'contactMechId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]telecomNumber = partyContactMech.getRelatedOne("TelecomNumber", false)

[MSG]The String 'TelecomNumber' can be wrapped in single quotes instead of double quotes

➥ EditPaymentMethod.groovy

Rule NamePriorityLine #Source Line / Message
IfStatementBraces241

[SRC]if (!tryEntity) creditCardData = parameters

[MSG]The if statement lacks braces

IfStatementBraces242

[SRC]if (!creditCardData) creditCardData = [:]

[MSG]The if statement lacks braces

IfStatementBraces243

[SRC]if (creditCardData) context.creditCardData = creditCardData

[MSG]The if statement lacks braces

IfStatementBraces246

[SRC]if (!tryEntity) giftCardData = parameters

[MSG]The if statement lacks braces

IfStatementBraces247

[SRC]if (!giftCardData) giftCardData = [:]

[MSG]The if statement lacks braces

IfStatementBraces248

[SRC]if (giftCardData) context.giftCardData = giftCardData

[MSG]The if statement lacks braces

IfStatementBraces251

[SRC]if (!tryEntity) eftAccountData = parameters

[MSG]The if statement lacks braces

IfStatementBraces252

[SRC]if (!eftAccountData) eftAccountData = [:]

[MSG]The if statement lacks braces

IfStatementBraces253

[SRC]if (eftAccountData) context.eftAccountData = eftAccountData

[MSG]The if statement lacks braces

IfStatementBraces256

[SRC]if (!tryEntity) paymentMethodData = parameters

[MSG]The if statement lacks braces

IfStatementBraces257

[SRC]if (!paymentMethodData) paymentMethodData = [:]

[MSG]The if statement lacks braces

IfStatementBraces258

[SRC]if (paymentMethodData) context.paymentMethodData = paymentMethodData

[MSG]The if statement lacks braces

LineLength261

[SRC]if (!security.hasEntityPermission("PARTYMGR", "_VIEW", s...partyId)) {

[MSG]The line exceeds 150 characters. The line is 217 characters.

ExplicitCallToEqualsMethod261

[SRC]if (!security.hasEntityPermission("PARTYMGR", "_VIEW", s...partyId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.customer.None. Explicit call to userLogin.partyId.equals(context.paymentMethod.partyId) method can be rewritten as (userLogin.partyId == (context.paymentMethod.partyId))

UnnecessaryGroovyImport321

[SRC]import java.util.HashMap

UnusedImport321

[SRC]import java.util.HashMap

[MSG]The [java.util.HashMap] import is never referenced

UnusedImport322

[SRC]import org.apache.ofbiz.base.util.UtilHttp

[MSG]The [org.apache.ofbiz.base.util.UtilHttp] import is never referenced

UnnecessaryGString335

[SRC]context.put("postalAddressInfos", postalAddressInfos)

[MSG]The String 'postalAddressInfos' can be wrapped in single quotes instead of double quotes

CouldBeElvis342

[SRC]if (!creditCardData) creditCardData = [:]

[MSG]Code could use elvis operator: creditCardData = creditCardData ?: [:]

CouldBeElvis347

[SRC]if (!giftCardData) giftCardData = [:]

[MSG]Code could use elvis operator: giftCardData = giftCardData ?: [:]

CouldBeElvis352

[SRC]if (!eftAccountData) eftAccountData = [:]

[MSG]Code could use elvis operator: eftAccountData = eftAccountData ?: [:]

CouldBeElvis357

[SRC]if (!paymentMethodData) paymentMethodData = [:]

[MSG]Code could use elvis operator: paymentMethodData = paymentMethodData ?: [:]

UnnecessaryGString361

[SRC]if (!security.hasEntityPermission("PARTYMGR", "_VIEW", s...partyId)) {

[MSG]The String 'PARTYMGR' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]if (!security.hasEntityPermission("PARTYMGR", "_VIEW", s...partyId)) {

[MSG]The String '_VIEW' can be wrapped in single quotes instead of double quotes

➥ EditPerson.groovy

Rule NamePriorityLine #Source Line / Message
IfStatementBraces230

[SRC]if (!tryEntity) personData = UtilHttp.getParameterMap(request)

[MSG]The if statement lacks braces

IfStatementBraces231

[SRC]if (!personData) personData = [:]

[MSG]The if statement lacks braces

UnnecessaryGroovyImport321

[SRC]import java.util.HashMap

UnusedImport321

[SRC]import java.util.HashMap

[MSG]The [java.util.HashMap] import is never referenced

CouldBeElvis331

[SRC]if (!personData) personData = [:]

[MSG]Code could use elvis operator: personData = personData ?: [:]

➥ EditShippingAddress.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod227

[SRC]if ("PERSON".equals(party.partyTypeId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.customer.None. Explicit call to PERSON.equals(party.partyTypeId) method can be rewritten as (PERSON == (party.partyTypeId))

UnnecessaryGString325

[SRC]party = userLogin.getRelatedOne("Party", false)

[MSG]The String 'Party' can be wrapped in single quotes instead of double quotes

UnnecessaryGString327

[SRC]if ("PERSON".equals(party.partyTypeId)) {

[MSG]The String 'PERSON' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]person = from("Person").where("partyId", party.partyId).queryOne()

[MSG]The String 'Person' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]person = from("Person").where("partyId", party.partyId).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]group = from("PartyGroup").where("partyId", party.partyId).queryOne()

[MSG]The String 'PartyGroup' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]group = from("PartyGroup").where("partyId", party.partyId).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]context.lastName = ""

[MSG]The String '' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]contactMech = EntityUtil.getFirst(ContactHelper.getConta..SS", false))

[MSG]The String 'SHIPPING_LOCATION' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]contactMech = EntityUtil.getFirst(ContactHelper.getConta..SS", false))

[MSG]The String 'POSTAL_ADDRESS' can be wrapped in single quotes instead of double quotes

UnnecessaryGString339

[SRC]postalAddress = contactMech.getRelatedOne("PostalAddress", false)

[MSG]The String 'PostalAddress' can be wrapped in single quotes instead of double quotes

UnnecessaryObjectReferences349

[SRC]context.shipToCountryGeoId = postalAddress.countryGeoId

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryGString350

[SRC]shipToStateProvinceGeo = from("Geo").where("geoId", post..).queryOne()

[MSG]The String 'Geo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]shipToStateProvinceGeo = from("Geo").where("geoId", post..).queryOne()

[MSG]The String 'geoId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString354

[SRC]shipToCountryProvinceGeo = from("Geo").where("geoId", po..).queryOne()

[MSG]The String 'Geo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString354

[SRC]shipToCountryProvinceGeo = from("Geo").where("geoId", po..).queryOne()

[MSG]The String 'geoId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString362

[SRC]shipToContactMechList = ContactHelper.getContactMech(par..BER", false)

[MSG]The String 'PHONE_SHIPPING' can be wrapped in single quotes instead of double quotes

UnnecessaryGString362

[SRC]shipToContactMechList = ContactHelper.getContactMech(par..BER", false)

[MSG]The String 'TELECOM_NUMBER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString364

[SRC]shipToTelecomNumber = (EntityUtil.getFirst(shipToContact..ber", false)

[MSG]The String 'TelecomNumber' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]pcm = EntityUtil.getFirst(shipToTelecomNumber.getRelated..ull, false))

[MSG]The String 'PartyContactMech' can be wrapped in single quotes instead of double quotes

UnnecessaryGString370

[SRC]shipToFaxNumberList = ContactHelper.getContactMech(party..BER", false)

[MSG]The String 'FAX_SHIPPING' can be wrapped in single quotes instead of double quotes

UnnecessaryGString370

[SRC]shipToFaxNumberList = ContactHelper.getContactMech(party..BER", false)

[MSG]The String 'TELECOM_NUMBER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString372

[SRC]shipToFaxNumber = (EntityUtil.getFirst(shipToFaxNumberLi..ber", false)

[MSG]The String 'TelecomNumber' can be wrapped in single quotes instead of double quotes

UnnecessaryGString373

[SRC]faxPartyContactMech = EntityUtil.getFirst(shipToFaxNumbe..ull, false))

[MSG]The String 'PartyContactMech' can be wrapped in single quotes instead of double quotes

➥ GiftCardBalance.groovy

Rule NamePriorityLine #Source Line / Message
NoWildcardImports321

[SRC]import org.apache.ofbiz.product.store.*

[MSG]Wildcard (star) import

Indentation322

[SRC]context.paymentProperties = ProductStoreWorker.getProduc.. null, true)

[MSG]The class None is at the incorrect indent level: Expected column 1 but was 2

MissingBlankLineAfterImports322

[SRC]context.paymentProperties = ProductStoreWorker.getProduc.. null, true)

[MSG]Missing blank line after imports in file GiftCardBalance.groovy

UnnecessaryGString322

[SRC]context.paymentProperties = ProductStoreWorker.getProduc.. null, true)

[MSG]The String 'GIFT_CARD' can be wrapped in single quotes instead of double quotes

➥ GiftCardLink.groovy

Rule NamePriorityLine #Source Line / Message
NoWildcardImports321

[SRC]import org.apache.ofbiz.product.store.*

[MSG]Wildcard (star) import

InvertedIfElse325

[SRC]if (!processResult) {

[MSG]Testing the negative condition first can make an if statement confusing

Indentation325

[SRC]if (!processResult) {

[MSG]The statement on line 25 in class org.apache.ofbiz.ecommerce.customer.None is at the incorrect indent level: Expected column 5 but was 4

Indentation326

[SRC]request.setAttribute("_ERROR_MESSAGE_", "<li>There was a..gain.</li>")

[MSG]The statement on line 26 in class org.apache.ofbiz.ecommerce.customer.None is at the incorrect indent level: Expected column 9 but was 8

UnnecessaryGString326

[SRC]request.setAttribute("_ERROR_MESSAGE_", "<li>There was a..gain.</li>")

[MSG]The String '_ERROR_MESSAGE_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString326

[SRC]request.setAttribute("_ERROR_MESSAGE_", "<li>There was a..gain.</li>")

[MSG]The String '<li>There was a problem linking your cards. Please check the numbers and try again.</li>' can be wrapped in single quotes instead of double quotes

Indentation327

[SRC]request.removeAttribute("_EVENT_MESSAGE_")

[MSG]The statement on line 27 in class org.apache.ofbiz.ecommerce.customer.None is at the incorrect indent level: Expected column 9 but was 8

UnnecessaryGString327

[SRC]request.removeAttribute("_EVENT_MESSAGE_")

[MSG]The String '_EVENT_MESSAGE_' can be wrapped in single quotes instead of double quotes

Indentation329

[SRC]request.setAttribute("_EVENT_MESSAGE_", "<li>Thank-you. ..nked.</li>")

[MSG]The statement on line 29 in class org.apache.ofbiz.ecommerce.customer.None is at the incorrect indent level: Expected column 9 but was 8

UnnecessaryGString329

[SRC]request.setAttribute("_EVENT_MESSAGE_", "<li>Thank-you. ..nked.</li>")

[MSG]The String '_EVENT_MESSAGE_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]request.setAttribute("_EVENT_MESSAGE_", "<li>Thank-you. ..nked.</li>")

[MSG]The String '<li>Thank-you. Your gift card account is now linked.</li>' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]context.paymentProperties = ProductStoreWorker.getProduc.. null, true)

[MSG]The String 'GIFT_CARD' can be wrapped in single quotes instead of double quotes

➥ NewCustomer.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod231

[SRC]context.createAllowPassword = "Y".equals(productStore.allowPassword)

[MSG]Violation in class org.apache.ofbiz.ecommerce.customer.None. Explicit call to Y.equals(productStore.allowPassword) method can be rewritten as (Y == (productStore.allowPassword))

ExplicitCallToEqualsMethod232

[SRC]context.getUsername = !"Y".equals(productStore.usePrimar..ailUsername)

[MSG]Violation in class org.apache.ofbiz.ecommerce.customer.None. Explicit call to Y.equals(productStore.usePrimaryEmailUsername) method can be rewritten as (Y == (productStore.usePrimaryEmailUsername))

UnusedImport321

[SRC]import org.apache.ofbiz.base.util.UtilProperties

[MSG]The [org.apache.ofbiz.base.util.UtilProperties] import is never referenced

UnusedImport323

[SRC]import org.apache.ofbiz.base.util.UtilMisc

[MSG]The [org.apache.ofbiz.base.util.UtilMisc] import is never referenced

DuplicateImport324

[SRC]import org.apache.ofbiz.base.util.UtilHttp

UnnecessaryGString331

[SRC]context.createAllowPassword = "Y".equals(productStore.allowPassword)

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]context.getUsername = !"Y".equals(productStore.usePrimar..ailUsername)

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]previousParams = "?" + previousParams

[MSG]The String '?' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]previousParams = ""

[MSG]The String '' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]userInfoMap = request.getAttribute("userInfoMap")

[MSG]The String 'userInfoMap' can be wrapped in single quotes instead of double quotes

CouldBeElvis344

[SRC]if (!userInfoMap) {

[MSG]Code could use elvis operator: userInfoMap = userInfoMap ?: request.getSession().getAttribute(userInfoMap)

UnnecessaryGString345

[SRC]userInfoMap = request.getSession().getAttribute("userInfoMap")

[MSG]The String 'userInfoMap' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]request.getSession().setAttribute("userInfoMap", userInfoMap)

[MSG]The String 'userInfoMap' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]donePage = "main;" + UtilHttp.getSessionId(request)

[MSG]The String 'main;' can be wrapped in single quotes instead of double quotes

➥ OnePageCheckoutOptions.groovy

Rule NamePriorityLine #Source Line / Message
NoWildcardImports321

[SRC]import org.apache.ofbiz.order.shoppingcart.shipping.*

[MSG]Wildcard (star) import

UnnecessaryGString323

[SRC]shoppingCart = session.getAttribute("shoppingCart")

[MSG]The String 'shoppingCart' can be wrapped in single quotes instead of double quotes

Indentation327

[SRC]shoppingCart.createDropShipGroups(dispatcher)

[MSG]The statement on line 27 in class org.apache.ofbiz.ecommerce.customer.None is at the incorrect indent level: Expected column 5 but was 3

➥ ViewProfile.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod237

[SRC]showOld = "true".equals(parameters.SHOW_OLD)

[MSG]Violation in class org.apache.ofbiz.ecommerce.customer.None. Explicit call to true.equals(parameters.SHOW_OLD) method can be rewritten as (true == (parameters.SHOW_OLD))

LineLength276

[SRC]result = runService('getOrderedSummaryInformation', [par.. userLogin])

[MSG]The line exceeds 150 characters. The line is 226 characters.

IfStatementBraces297

[SRC]if (countryGeo) it.countryGeoName = countryGeo.getString("geoName")

[MSG]The if statement lacks braces

IfStatementBraces299

[SRC]if (stateProvinceGeo) it.stateProvinceGeoName = statePro..g("geoName")

[MSG]The if statement lacks braces

NoWildcardImports321

[SRC]import java.lang.*

[MSG]Wildcard (star) import

UnnecessaryGroovyImport321

[SRC]import java.lang.*

NoWildcardImports322

[SRC]import java.util.*

[MSG]Wildcard (star) import

UnnecessaryGroovyImport322

[SRC]import java.util.*

NoWildcardImports323

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.entity.util.*

[MSG]Wildcard (star) import

NoWildcardImports326

[SRC]import org.apache.ofbiz.entity.condition.*

[MSG]Wildcard (star) import

UnnecessaryGString335

[SRC]profiledefs = from("PartyProfileDefault").where("partyId..).queryOne()

[MSG]The String 'PartyProfileDefault' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]profiledefs = from("PartyProfileDefault").where("partyId..).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]profiledefs = from("PartyProfileDefault").where("partyId..).queryOne()

[MSG]The String 'productStoreId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]showOld = "true".equals(parameters.SHOW_OLD)

[MSG]The String 'true' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]shipAddress = from("PostalAddress").where("contactMechId..).queryOne()

[MSG]The String 'PostalAddress' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]shipAddress = from("PostalAddress").where("contactMechId..).queryOne()

[MSG]The String 'contactMechId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]profileSurveys = ProductStoreWorker.getProductSurveys(de..ER_PROFILE")

[MSG]The String 'CUSTOMER_PROFILE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString359

[SRC]exprs = [EntityCondition.makeCondition("partyId", Entity..S, partyId)]

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]exprs.add(EntityCondition.makeCondition("roleStatusId", ..ROLE_READ"))

[MSG]The String 'roleStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]exprs.add(EntityCondition.makeCondition("roleStatusId", ..ROLE_READ"))

[MSG]The String 'COM_ROLE_READ' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]messages = from("CommunicationEventAndRole").where(exprs...queryList()

[MSG]The String 'CommunicationEventAndRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]messages = from("CommunicationEventAndRole").where(exprs...queryList()

[MSG]The String '-entryDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]partyContent = from("ContentRole").where("partyId", part...queryList()

[MSG]The String 'ContentRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]partyContent = from("ContentRole").where("partyId", part...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]partyContent = from("ContentRole").where("partyId", part...queryList()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]partyContent = from("ContentRole").where("partyId", part...queryList()

[MSG]The String 'OWNER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]mimeTypes = from("MimeType").orderBy("description", "mim...queryList()

[MSG]The String 'MimeType' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]mimeTypes = from("MimeType").orderBy("description", "mim...queryList()

[MSG]The String 'description' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]mimeTypes = from("MimeType").orderBy("description", "mim...queryList()

[MSG]The String 'mimeTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString371

[SRC]partyContentTypes = from("PartyContentType").orderBy("de...queryList()

[MSG]The String 'PartyContentType' can be wrapped in single quotes instead of double quotes

UnnecessaryGString371

[SRC]partyContentTypes = from("PartyContentType").orderBy("de...queryList()

[MSG]The String 'description' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon376

[SRC]result = runService('getOrderedSummaryInformation', [par.. userLogin])

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.ecommerce.customer.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon376

[SRC]result = runService('getOrderedSummaryInformation', [par.. userLogin])

[MSG]The colon for the literal Map entry for key [roleTypeId] within class org.apache.ofbiz.ecommerce.customer.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon376

[SRC]result = runService('getOrderedSummaryInformation', [par.. userLogin])

[MSG]The colon for the literal Map entry for key [orderTypeId] within class org.apache.ofbiz.ecommerce.customer.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon376

[SRC]result = runService('getOrderedSummaryInformation', [par.. userLogin])

[MSG]The colon for the literal Map entry for key [statusId] within class org.apache.ofbiz.ecommerce.customer.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon376

[SRC]result = runService('getOrderedSummaryInformation', [par.. userLogin])

[MSG]The colon for the literal Map entry for key [monthsToInclude] within class org.apache.ofbiz.ecommerce.customer.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon376

[SRC]result = runService('getOrderedSummaryInformation', [par.. userLogin])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.ecommerce.customer.None is not preceded by a match for regular expression [\S]

UnnecessaryGString376

[SRC]result = runService('getOrderedSummaryInformation', [par.. userLogin])

[MSG]The String 'PLACING_CUSTOMER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString376

[SRC]result = runService('getOrderedSummaryInformation', [par.. userLogin])

[MSG]The String 'SALES_ORDER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString376

[SRC]result = runService('getOrderedSummaryInformation', [par.. userLogin])

[MSG]The String 'ORDER_COMPLETED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString381

[SRC]contactListPartyList = from("ContactListParty").where("p...queryList()

[MSG]The String 'ContactListParty' can be wrapped in single quotes instead of double quotes

UnnecessaryGString381

[SRC]contactListPartyList = from("ContactListParty").where("p...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString381

[SRC]contactListPartyList = from("ContactListParty").where("p...queryList()

[MSG]The String '-fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString385

[SRC]publicContactLists = from("ContactList").where("isPublic...queryList()

[MSG]The String 'ContactList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString385

[SRC]publicContactLists = from("ContactList").where("isPublic...queryList()

[MSG]The String 'isPublic' can be wrapped in single quotes instead of double quotes

UnnecessaryGString385

[SRC]publicContactLists = from("ContactList").where("isPublic...queryList()

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString385

[SRC]publicContactLists = from("ContactList").where("isPublic...queryList()

[MSG]The String 'contactListName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString388

[SRC]partyAndContactMechList = from("PartyAndContactMech").wh...queryList()

[MSG]The String 'PartyAndContactMech' can be wrapped in single quotes instead of double quotes

UnnecessaryGString388

[SRC]partyAndContactMechList = from("PartyAndContactMech").wh...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString388

[SRC]partyAndContactMechList = from("PartyAndContactMech").wh...queryList()

[MSG]The String '-fromDate' can be wrapped in single quotes instead of double quotes

TrailingWhitespace390

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString396

[SRC]countryGeo = postalAddress.getRelatedOne("CountryGeo", false)

[MSG]The String 'CountryGeo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString397

[SRC]if (countryGeo) it.countryGeoName = countryGeo.getString("geoName")

[MSG]The String 'geoName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString398

[SRC]stateProvinceGeo = postalAddress.getRelatedOne("StatePro..Geo", false)

[MSG]The String 'StateProvinceGeo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString399

[SRC]if (stateProvinceGeo) it.stateProvinceGeoName = statePro..g("geoName")

[MSG]The String 'geoName' can be wrapped in single quotes instead of double quotes

BlockEndsWithBlankLine3100

[MSG]Code block ends with a blank line.

TrailingWhitespace3100

[SRC]

[MSG]Line ends with whitespace characters

Package: org.apache.ofbiz.ecommerce.forum

➥ ContentAddPrep.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGroovyImport321

[SRC]import java.util.ArrayList

UnusedImport321

[SRC]import java.util.ArrayList

[MSG]The [java.util.ArrayList] import is never referenced

UnnecessaryGroovyImport322

[SRC]import java.util.Collection

UnusedImport322

[SRC]import java.util.Collection

[MSG]The [java.util.Collection] import is never referenced

UnnecessaryGroovyImport323

[SRC]import java.util.HashMap

UnusedImport323

[SRC]import java.util.HashMap

[MSG]The [java.util.HashMap] import is never referenced

UnnecessaryGroovyImport324

[SRC]import java.util.Iterator

UnusedImport324

[SRC]import java.util.Iterator

[MSG]The [java.util.Iterator] import is never referenced

UnnecessaryGroovyImport325

[SRC]import java.util.LinkedList

UnusedImport325

[SRC]import java.util.LinkedList

[MSG]The [java.util.LinkedList] import is never referenced

UnnecessaryGroovyImport326

[SRC]import java.util.List

UnusedImport326

[SRC]import java.util.List

[MSG]The [java.util.List] import is never referenced

UnnecessaryGroovyImport327

[SRC]import java.util.Map

UnusedImport327

[SRC]import java.util.Map

[MSG]The [java.util.Map] import is never referenced

UnnecessaryGroovyImport328

[SRC]import java.util.Set

UnusedImport328

[SRC]import java.util.Set

[MSG]The [java.util.Set] import is never referenced

UnnecessaryGroovyImport329

[SRC]import java.util.TreeSet

UnusedImport329

[SRC]import java.util.TreeSet

[MSG]The [java.util.TreeSet] import is never referenced

NoWildcardImports330

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports331

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports332

[SRC]import org.apache.ofbiz.security.*

[MSG]Wildcard (star) import

NoWildcardImports333

[SRC]import org.apache.ofbiz.service.*

[MSG]Wildcard (star) import

NoWildcardImports334

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

NoWildcardImports334

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

NoWildcardImports335

[SRC]import org.apache.ofbiz.securityext.login.*

[MSG]Wildcard (star) import

NoWildcardImports336

[SRC]import org.apache.ofbiz.common.*

[MSG]Wildcard (star) import

DuplicateImport337

[SRC]import org.apache.ofbiz.entity.model.*

UnusedImport339

[SRC]import org.apache.ofbiz.content.content.ContentWorker

[MSG]The [org.apache.ofbiz.content.content.ContentWorker] import is never referenced

UnusedImport341

[SRC]import freemarker.template.SimpleHash

[MSG]The [freemarker.template.SimpleHash] import is never referenced

UnusedImport342

[SRC]import freemarker.template.SimpleSequence

[MSG]The [freemarker.template.SimpleSequence] import is never referenced

NoWildcardImports344

[SRC]import javax.servlet.*

[MSG]Wildcard (star) import

NoWildcardImports345

[SRC]import javax.servlet.http.*

[MSG]Wildcard (star) import

UnnecessaryGString348

[SRC]singleWrapper.putInContext("contentPurposeTypeId", page...rposeTypeId)

[MSG]The String 'contentPurposeTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]singleWrapper.putInContext("contentAssocTypeId", page.co..AssocTypeId)

[MSG]The String 'contentAssocTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString352

[SRC]contentIdTo = ContentManagementWorker.getFromSomewhere("..st, context)

[MSG]The String 'forumId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]attrList = from("ContentAttribute").where("contentId", c...queryList()

[MSG]The String 'ContentAttribute' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]attrList = from("ContentAttribute").where("contentId", c...queryList()

[MSG]The String 'contentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]attrList = from("ContentAttribute").where("contentId", c...queryList()

[MSG]The String 'attrName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]attrList = from("ContentAttribute").where("contentId", c...queryList()

[MSG]The String 'publishOperation' can be wrapped in single quotes instead of double quotes

UnnecessaryGString364

[SRC]singleWrapper.putInContext("publishOperation", publishOperation)

[MSG]The String 'publishOperation' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]singleWrapper.putInContext("contentIdTo", contentIdTo)

[MSG]The String 'contentIdTo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]singleWrapper.putInContext("summaryDataResourceTypeId", ..ourceTypeId)

[MSG]The String 'summaryDataResourceTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString369

[SRC]targetOperation = page.targetOperation ?: "CONTENT_CREATE"

[MSG]The String 'CONTENT_CREATE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString371

[SRC]singleWrapper.putInContext("targetOperation", targetOperation)

[MSG]The String 'targetOperation' can be wrapped in single quotes instead of double quotes

UnnecessaryGString372

[SRC]singleWrapper.putInContext("contentTypeId", "DOCUMENT")

[MSG]The String 'contentTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString372

[SRC]singleWrapper.putInContext("contentTypeId", "DOCUMENT")

[MSG]The String 'DOCUMENT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString373

[SRC]contentPurpose = page.contentPurpose ?: "ARTICLE"

[MSG]The String 'ARTICLE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString375

[SRC]singleWrapper.putInContext("contentPurpose", contentPurpose)

[MSG]The String 'contentPurpose' can be wrapped in single quotes instead of double quotes

UnnecessaryGString376

[SRC]singleWrapper.putInContext("forumId", contentIdTo)

[MSG]The String 'forumId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString378

[SRC]forumContent = from("Content").where("contentId", conten..).queryOne()

[MSG]The String 'Content' can be wrapped in single quotes instead of double quotes

UnnecessaryGString378

[SRC]forumContent = from("Content").where("contentId", conten..).queryOne()

[MSG]The String 'contentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString379

[SRC]statusId = "CTNT_PUBLISHED"

[MSG]The String 'CTNT_PUBLISHED' can be wrapped in single quotes instead of double quotes

CouldBeElvis382

[SRC]if (!statusId) {

[MSG]Code could use elvis operator: statusId = statusId ?: page.statusId

CouldBeElvis385

[SRC]if (!statusId) {

[MSG]Code could use elvis operator: statusId = statusId ?: 'CTNT_PUBLISHED'

UnnecessaryGString386

[SRC]statusId = "CTNT_PUBLISHED"

[MSG]The String 'CTNT_PUBLISHED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString389

[SRC]singleWrapper.putInContext("statusId", statusId)

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

➥ ContentPrep.groovy

Rule NamePriorityLine #Source Line / Message
IfStatementBraces248

[SRC]if (!contentId)

[MSG]The if statement lacks braces

IfStatementBraces250

[SRC]if (!contentId)

[MSG]The if statement lacks braces

NoWildcardImports321

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.security.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.service.*

[MSG]Wildcard (star) import

NoWildcardImports326

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

UnnecessaryGroovyImport331

[SRC]import java.io.StringWriter

NoWildcardImports335

[SRC]import javax.servlet.*

[MSG]Wildcard (star) import

NoWildcardImports336

[SRC]import javax.servlet.http.*

[MSG]Wildcard (star) import

UnnecessaryGString346

[SRC]contentId = ""

[MSG]The String '' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]contentId = ContentManagementWorker.getFromSomewhere("ma..st, context)

[MSG]The String 'masterContentId' can be wrapped in single quotes instead of double quotes

CouldBeElvis348

[SRC]if (!contentId)

[MSG]Code could use elvis operator: contentId = contentId ?: ContentManagementWorker.getFromSomewhere(contentIdTo, paramMap, request, context)

UnnecessaryGString349

[SRC]contentId = ContentManagementWorker.getFromSomewhere("co..st, context)

[MSG]The String 'contentIdTo' can be wrapped in single quotes instead of double quotes

CouldBeElvis350

[SRC]if (!contentId)

[MSG]Code could use elvis operator: contentId = contentId ?: ContentManagementWorker.getFromSomewhere(contentId, paramMap, request, context)

UnnecessaryGString351

[SRC]contentId = ContentManagementWorker.getFromSomewhere("co..st, context)

[MSG]The String 'contentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]currentValue = from("Content").where("contentId", conten..).queryOne()

[MSG]The String 'Content' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]currentValue = from("Content").where("contentId", conten..).queryOne()

[MSG]The String 'contentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString374

[SRC]rootDir = request.getSession().getServletContext().getRealPath("/")

[MSG]The String '/' can be wrapped in single quotes instead of double quotes

UnnecessaryGString388

[SRC]subContentDataResourceView = ContentWorker.getSubContent..s, fromDate)

[MSG]The String 'ARTICLE' can be wrapped in single quotes instead of double quotes

Indentation3100

[SRC]singleWrapper.putInContext("textData", textData)

[MSG]The statement on line 100 in class org.apache.ofbiz.ecommerce.forum.None is at the incorrect indent level: Expected column 13 but was 12

UnnecessaryGString3100

[SRC]singleWrapper.putInContext("textData", textData)

[MSG]The String 'textData' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3104

[SRC]subContentDataResourceView = ContentWorker.getSubContent..mDate, true)

[MSG]The String 'SUMMARY' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3116

[SRC]singleWrapper.putInContext("summaryData", summaryData)

[MSG]The String 'summaryData' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3120

[SRC]subContentDataResourceView = ContentWorker.getSubContent..mDate, true)

[MSG]The String 'IMAGE' can be wrapped in single quotes instead of double quotes

➥ CurrentValPrep.groovy

Rule NamePriorityLine #Source Line / Message
EmptyIfStatement2100

[SRC]if (!sPassed.equals(sCached)) {

[MSG]The if statement is empty

ExplicitCallToEqualsMethod2100

[SRC]if (!sPassed.equals(sCached)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.forum.None. Explicit call to sPassed.equals(sCached) method can be rewritten as (sPassed == (sCached))

IfStatementBraces2131

[SRC]if (s) suffix = "_" + s

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2133

[SRC]if ("_ELECTRONIC_TEXT".equals(suffix)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.forum.None. Explicit call to _ELECTRONIC_TEXT.equals(suffix) method can be rewritten as (_ELECTRONIC_TEXT == (suffix))

IfStatementBraces2135

[SRC]if (s) suffix += "_" + s

[MSG]The if statement lacks braces

UnnecessaryGroovyImport321

[SRC]import java.util.ArrayList

UnusedImport321

[SRC]import java.util.ArrayList

[MSG]The [java.util.ArrayList] import is never referenced

UnnecessaryGroovyImport322

[SRC]import java.util.Collection

UnusedImport322

[SRC]import java.util.Collection

[MSG]The [java.util.Collection] import is never referenced

UnnecessaryGroovyImport323

[SRC]import java.util.HashMap

UnusedImport323

[SRC]import java.util.HashMap

[MSG]The [java.util.HashMap] import is never referenced

UnnecessaryGroovyImport324

[SRC]import java.util.Iterator

UnusedImport324

[SRC]import java.util.Iterator

[MSG]The [java.util.Iterator] import is never referenced

UnnecessaryGroovyImport325

[SRC]import java.util.LinkedList

UnusedImport325

[SRC]import java.util.LinkedList

[MSG]The [java.util.LinkedList] import is never referenced

UnnecessaryGroovyImport326

[SRC]import java.util.List

UnusedImport326

[SRC]import java.util.List

[MSG]The [java.util.List] import is never referenced

UnnecessaryGroovyImport327

[SRC]import java.util.Map

UnusedImport327

[SRC]import java.util.Map

[MSG]The [java.util.Map] import is never referenced

UnnecessaryGroovyImport328

[SRC]import java.util.Set

UnusedImport328

[SRC]import java.util.Set

[MSG]The [java.util.Set] import is never referenced

UnnecessaryGroovyImport329

[SRC]import java.util.TreeSet

UnusedImport329

[SRC]import java.util.TreeSet

[MSG]The [java.util.TreeSet] import is never referenced

NoWildcardImports330

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports331

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports332

[SRC]import org.apache.ofbiz.security.*

[MSG]Wildcard (star) import

NoWildcardImports333

[SRC]import org.apache.ofbiz.service.*

[MSG]Wildcard (star) import

NoWildcardImports334

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

NoWildcardImports337

[SRC]import javax.servlet.*

[MSG]Wildcard (star) import

NoWildcardImports338

[SRC]import javax.servlet.http.*

[MSG]Wildcard (star) import

UnnecessaryGString340

[SRC]currentEntityMap = session.getAttribute("currentEntityMap")

[MSG]The String 'currentEntityMap' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]session.setAttribute("currentEntityMap", currentEntityMap)

[MSG]The String 'currentEntityMap' can be wrapped in single quotes instead of double quotes

InvertedIfElse348

[SRC]if (!currentEntityPropertyName) {

[MSG]Testing the negative condition first can make an if statement confusing

InvertedIfElse391

[SRC]if (!sPassed) {

[MSG]Testing the negative condition first can make an if statement confusing

InvertedIfElse397

[SRC]if (!sPassed) {

[MSG]Testing the negative condition first can make an if statement confusing

UnnecessaryGString3120

[SRC]request.setAttribute("currentPK", currentPK)

[MSG]The String 'currentPK' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3124

[SRC]request.setAttribute("currentValue", currentValue)

[MSG]The String 'currentValue' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3128

[SRC]if (currentEntityName.indexOf("DataResource") >= 0) {

[MSG]The String 'DataResource' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3129

[SRC]suffix = ""

[MSG]The String '' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3131

[SRC]if (s) suffix = "_" + s

[MSG]The String '_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3133

[SRC]if ("_ELECTRONIC_TEXT".equals(suffix)) {

[MSG]The String '_ELECTRONIC_TEXT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3135

[SRC]if (s) suffix += "_" + s

[MSG]The String '_' can be wrapped in single quotes instead of double quotes

➥ EditAddPrep.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod253

[SRC]if ("SUMMARY".equals(mapKey)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.forum.None. Explicit call to SUMMARY.equals(mapKey) method can be rewritten as (SUMMARY == (mapKey))

ExplicitCallToEqualsMethod273

[SRC]if ("SUMMARY".equals(mapKey)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.forum.None. Explicit call to SUMMARY.equals(mapKey) method can be rewritten as (SUMMARY == (mapKey))

UnnecessaryGroovyImport321

[SRC]import java.util.ArrayList

UnusedImport321

[SRC]import java.util.ArrayList

[MSG]The [java.util.ArrayList] import is never referenced

UnnecessaryGroovyImport322

[SRC]import java.util.Collection

UnusedImport322

[SRC]import java.util.Collection

[MSG]The [java.util.Collection] import is never referenced

UnnecessaryGroovyImport323

[SRC]import java.util.HashMap

UnusedImport323

[SRC]import java.util.HashMap

[MSG]The [java.util.HashMap] import is never referenced

UnnecessaryGroovyImport324

[SRC]import java.util.Iterator

UnusedImport324

[SRC]import java.util.Iterator

[MSG]The [java.util.Iterator] import is never referenced

UnnecessaryGroovyImport325

[SRC]import java.util.LinkedList

UnusedImport325

[SRC]import java.util.LinkedList

[MSG]The [java.util.LinkedList] import is never referenced

UnnecessaryGroovyImport326

[SRC]import java.util.List

UnusedImport326

[SRC]import java.util.List

[MSG]The [java.util.List] import is never referenced

UnnecessaryGroovyImport327

[SRC]import java.util.Map

UnusedImport327

[SRC]import java.util.Map

[MSG]The [java.util.Map] import is never referenced

UnnecessaryGroovyImport328

[SRC]import java.util.Set

UnusedImport328

[SRC]import java.util.Set

[MSG]The [java.util.Set] import is never referenced

UnnecessaryGroovyImport329

[SRC]import java.util.TreeSet

UnusedImport329

[SRC]import java.util.TreeSet

[MSG]The [java.util.TreeSet] import is never referenced

NoWildcardImports330

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports331

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports332

[SRC]import org.apache.ofbiz.security.*

[MSG]Wildcard (star) import

NoWildcardImports333

[SRC]import org.apache.ofbiz.service.*

[MSG]Wildcard (star) import

NoWildcardImports334

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

NoWildcardImports334

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

NoWildcardImports335

[SRC]import org.apache.ofbiz.securityext.login.*

[MSG]Wildcard (star) import

NoWildcardImports336

[SRC]import org.apache.ofbiz.common.*

[MSG]Wildcard (star) import

DuplicateImport337

[SRC]import org.apache.ofbiz.entity.model.*

UnusedImport338

[SRC]import org.apache.ofbiz.content.ContentManagementWorker

[MSG]The [org.apache.ofbiz.content.ContentManagementWorker] import is never referenced

UnusedImport341

[SRC]import freemarker.template.SimpleHash

[MSG]The [freemarker.template.SimpleHash] import is never referenced

UnusedImport342

[SRC]import freemarker.template.SimpleSequence

[MSG]The [freemarker.template.SimpleSequence] import is never referenced

NoWildcardImports344

[SRC]import javax.servlet.*

[MSG]Wildcard (star) import

NoWildcardImports345

[SRC]import javax.servlet.http.*

[MSG]Wildcard (star) import

UnnecessaryGString349

[SRC]singleWrapper.putInContext("contentIdTo", contentIdTo)

[MSG]The String 'contentIdTo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString351

[SRC]singleWrapper.putInContext("mapKey", mapKey)

[MSG]The String 'mapKey' can be wrapped in single quotes instead of double quotes

UnnecessaryGString353

[SRC]if ("SUMMARY".equals(mapKey)) {

[MSG]The String 'SUMMARY' can be wrapped in single quotes instead of double quotes

UnnecessaryGString354

[SRC]singleWrapper.putInContext("textSource", "summaryData")

[MSG]The String 'textSource' can be wrapped in single quotes instead of double quotes

UnnecessaryGString354

[SRC]singleWrapper.putInContext("textSource", "summaryData")

[MSG]The String 'summaryData' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]singleWrapper.putInContext("textSource", "textData")

[MSG]The String 'textSource' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]singleWrapper.putInContext("textSource", "textData")

[MSG]The String 'textData' can be wrapped in single quotes instead of double quotes

UnnecessaryGString359

[SRC]singleWrapper.putInContext("dataResourceTypeId", "ELECTRONIC_TEXT")

[MSG]The String 'dataResourceTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString359

[SRC]singleWrapper.putInContext("dataResourceTypeId", "ELECTRONIC_TEXT")

[MSG]The String 'ELECTRONIC_TEXT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]singleWrapper.putInContext("contentAssocTypeId", "SUB_CONTENT")

[MSG]The String 'contentAssocTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]singleWrapper.putInContext("contentAssocTypeId", "SUB_CONTENT")

[MSG]The String 'SUB_CONTENT' can be wrapped in single quotes instead of double quotes

InvertedIfElse369

[SRC]if (!currentValue) {

[MSG]Testing the negative condition first can make an if statement confusing

UnnecessaryGString370

[SRC]parentValue = from("Content").where("contentId", content..).queryOne()

[MSG]The String 'Content' can be wrapped in single quotes instead of double quotes

UnnecessaryGString370

[SRC]parentValue = from("Content").where("contentId", content..).queryOne()

[MSG]The String 'contentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString371

[SRC]currentValue = makeValue("Content")

[MSG]The String 'Content' can be wrapped in single quotes instead of double quotes

UnnecessaryGString373

[SRC]if ("SUMMARY".equals(mapKey)) {

[MSG]The String 'SUMMARY' can be wrapped in single quotes instead of double quotes

UnnecessaryGString374

[SRC]subject = "Short " + subject

[MSG]The String 'Short ' can be wrapped in single quotes instead of double quotes

UnnecessaryGString378

[SRC]singleWrapper.putInContext("contentTypeId", "DOCUMENT")

[MSG]The String 'contentTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString378

[SRC]singleWrapper.putInContext("contentTypeId", "DOCUMENT")

[MSG]The String 'DOCUMENT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]singleWrapper.putInContext("contentTypeId", null)

[MSG]The String 'contentTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString383

[SRC]singleWrapper.putInContext("currentValue", currentValue)

[MSG]The String 'currentValue' can be wrapped in single quotes instead of double quotes

UnnecessaryGString385

[SRC]request.setAttribute("currentValue", currentValue)

[MSG]The String 'currentValue' can be wrapped in single quotes instead of double quotes

UnnecessaryGString386

[SRC]persistAction = parameters.persistAction ?: "persistContent"

[MSG]The String 'persistContent' can be wrapped in single quotes instead of double quotes

UnnecessaryGString388

[SRC]singleWrapper.putInContext("persistAction", persistAction)

[MSG]The String 'persistAction' can be wrapped in single quotes instead of double quotes

➥ HtmlAreaPrep.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod239

[SRC]if (!contentIdTo || !"TEMPLATE_MASTER".equals(contentIdTo)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.forum.None. Explicit call to TEMPLATE_MASTER.equals(contentIdTo) method can be rewritten as (TEMPLATE_MASTER == (contentIdTo))

NoWildcardImports321

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports322

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.security.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.service.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

UnusedImport326

[SRC]import org.apache.ofbiz.content.data.DataResourceWorker

[MSG]The [org.apache.ofbiz.content.data.DataResourceWorker] import is never referenced

UnusedImport327

[SRC]import org.apache.ofbiz.webapp.ftl.FreeMarkerViewHandler

[MSG]The [org.apache.ofbiz.webapp.ftl.FreeMarkerViewHandler] import is never referenced

UnnecessaryGroovyImport329

[SRC]import java.io.StringWriter

UnusedImport329

[SRC]import java.io.StringWriter

[MSG]The [java.io.StringWriter] import is never referenced

UnusedImport330

[SRC]import freemarker.ext.beans.BeansWrapper

[MSG]The [freemarker.ext.beans.BeansWrapper] import is never referenced

UnusedImport331

[SRC]import freemarker.template.SimpleHash

[MSG]The [freemarker.template.SimpleHash] import is never referenced

UnusedImport332

[SRC]import freemarker.template.WrappingTemplateModel

[MSG]The [freemarker.template.WrappingTemplateModel] import is never referenced

NoWildcardImports334

[SRC]import javax.servlet.*

[MSG]Wildcard (star) import

NoWildcardImports335

[SRC]import javax.servlet.http.*

[MSG]Wildcard (star) import

UnnecessaryGString339

[SRC]if (!contentIdTo || !"TEMPLATE_MASTER".equals(contentIdTo)) {

[MSG]The String 'TEMPLATE_MASTER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]context.dynamicPrimaryHTMLField = "textData"

[MSG]The String 'textData' can be wrapped in single quotes instead of double quotes

➥ NodeTrailPrep.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGroovyImport321

[SRC]import java.util.ArrayList

UnusedImport321

[SRC]import java.util.ArrayList

[MSG]The [java.util.ArrayList] import is never referenced

UnnecessaryGroovyImport322

[SRC]import java.util.Collection

UnusedImport322

[SRC]import java.util.Collection

[MSG]The [java.util.Collection] import is never referenced

UnnecessaryGroovyImport323

[SRC]import java.util.HashMap

UnusedImport323

[SRC]import java.util.HashMap

[MSG]The [java.util.HashMap] import is never referenced

UnnecessaryGroovyImport324

[SRC]import java.util.Iterator

UnusedImport324

[SRC]import java.util.Iterator

[MSG]The [java.util.Iterator] import is never referenced

UnnecessaryGroovyImport325

[SRC]import java.util.LinkedList

UnusedImport325

[SRC]import java.util.LinkedList

[MSG]The [java.util.LinkedList] import is never referenced

UnnecessaryGroovyImport326

[SRC]import java.util.List

UnusedImport326

[SRC]import java.util.List

[MSG]The [java.util.List] import is never referenced

UnnecessaryGroovyImport327

[SRC]import java.util.Map

UnnecessaryGroovyImport328

[SRC]import java.util.Set

UnusedImport328

[SRC]import java.util.Set

[MSG]The [java.util.Set] import is never referenced

UnnecessaryGroovyImport329

[SRC]import java.util.TreeSet

UnusedImport329

[SRC]import java.util.TreeSet

[MSG]The [java.util.TreeSet] import is never referenced

NoWildcardImports331

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports332

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports333

[SRC]import org.apache.ofbiz.security.*

[MSG]Wildcard (star) import

NoWildcardImports334

[SRC]import org.apache.ofbiz.service.*

[MSG]Wildcard (star) import

NoWildcardImports335

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

NoWildcardImports335

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

NoWildcardImports336

[SRC]import org.apache.ofbiz.securityext.login.*

[MSG]Wildcard (star) import

NoWildcardImports337

[SRC]import org.apache.ofbiz.common.*

[MSG]Wildcard (star) import

DuplicateImport338

[SRC]import org.apache.ofbiz.entity.model.*

NoWildcardImports342

[SRC]import javax.servlet.*

[MSG]Wildcard (star) import

NoWildcardImports343

[SRC]import javax.servlet.http.*

[MSG]Wildcard (star) import

UnnecessaryGString345

[SRC]nodeTrailCsv = ContentManagementWorker.getFromSomewhere(..st, context)

[MSG]The String 'nodeTrailCsv' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]passedParams = request.getAttribute("passedParams")

[MSG]The String 'passedParams' can be wrapped in single quotes instead of double quotes

SpaceAfterComma361

[SRC]singleWrapper.putInContext("nodeTrailCsv",nodeTrailCsv)

[MSG]The parameter nodeTrailCsv in the call to method putInContext within class org.apache.ofbiz.ecommerce.forum.None is not preceded by a space or whitespace

UnnecessaryGString361

[SRC]singleWrapper.putInContext("nodeTrailCsv",nodeTrailCsv)

[MSG]The String 'nodeTrailCsv' can be wrapped in single quotes instead of double quotes

UnnecessaryGString366

[SRC]Map dummy = singleWrapper.getFromContext("dummy")

[MSG]The String 'dummy' can be wrapped in single quotes instead of double quotes

CouldBeElvis367

[SRC]if (!dummy) {

[MSG]Code could use elvis operator: dummy = dummy ?: [:]

Indentation368

[SRC]dummy = [:]

[MSG]The statement on line 68 in class org.apache.ofbiz.ecommerce.forum.None is at the incorrect indent level: Expected column 13 but was 12

SpaceAfterComma372

[SRC]singleWrapper.putInContext("dummy",dummy)

[MSG]The parameter dummy in the call to method putInContext within class org.apache.ofbiz.ecommerce.forum.None is not preceded by a space or whitespace

UnnecessaryGString372

[SRC]singleWrapper.putInContext("dummy",dummy)

[MSG]The String 'dummy' can be wrapped in single quotes instead of double quotes

➥ OwnerContentPrep.groovy

Rule NamePriorityLine #Source Line / Message
LineLength250

[SRC]departmentPointList = ContentManagementWorker.getPermitt..ATE", null )

[MSG]The line exceeds 150 characters. The line is 172 characters.

NoWildcardImports321

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports322

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.security.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.service.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

UnusedImport326

[SRC]import org.apache.ofbiz.content.data.DataResourceWorker

[MSG]The [org.apache.ofbiz.content.data.DataResourceWorker] import is never referenced

UnusedImport327

[SRC]import org.apache.ofbiz.webapp.ftl.FreeMarkerViewHandler

[MSG]The [org.apache.ofbiz.webapp.ftl.FreeMarkerViewHandler] import is never referenced

UnusedImport328

[SRC]import org.apache.ofbiz.content.content.ContentWorker

[MSG]The [org.apache.ofbiz.content.content.ContentWorker] import is never referenced

UnnecessaryGroovyImport331

[SRC]import java.io.StringWriter

UnusedImport331

[SRC]import java.io.StringWriter

[MSG]The [java.io.StringWriter] import is never referenced

UnusedImport332

[SRC]import freemarker.ext.beans.BeansWrapper

[MSG]The [freemarker.ext.beans.BeansWrapper] import is never referenced

UnusedImport333

[SRC]import freemarker.template.SimpleHash

[MSG]The [freemarker.template.SimpleHash] import is never referenced

UnusedImport334

[SRC]import freemarker.template.WrappingTemplateModel

[MSG]The [freemarker.template.WrappingTemplateModel] import is never referenced

NoWildcardImports336

[SRC]import javax.servlet.*

[MSG]Wildcard (star) import

NoWildcardImports337

[SRC]import javax.servlet.http.*

[MSG]Wildcard (star) import

UnnecessaryGString350

[SRC]departmentPointList = ContentManagementWorker.getPermitt..ATE", null )

[MSG]The String 'CONTENT_CREATE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString369

[SRC]lineMap2.description = "&nbsp;&nbsp;&nbsp;-" + description2

[MSG]The String '&nbsp;&nbsp;&nbsp;-' can be wrapped in single quotes instead of double quotes

UnnecessaryGString378

[SRC]singleWrapper.putInContext("ownerContentList", ownerContentList)

[MSG]The String 'ownerContentList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString379

[SRC]singleWrapper.putInContext("pubPt", pubPt)

[MSG]The String 'pubPt' can be wrapped in single quotes instead of double quotes

➥ PermPrep.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod260

[SRC]if ("add".equals(mode)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.forum.None. Explicit call to add.equals(mode) method can be rewritten as (add == (mode))

ExplicitCallToEqualsMethod273

[SRC]if ("complex".equals(permissionType)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.forum.None. Explicit call to complex.equals(permissionType) method can be rewritten as (complex == (permissionType))

ExplicitCallToEqualsMethod284

[SRC]if (!currentValue || !"Content".equals(entityName)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.forum.None. Explicit call to Content.equals(entityName) method can be rewritten as (Content == (entityName))

ExplicitCallToEqualsMethod2102

[SRC]if (!currentValue || !"Content".equals(entityName)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.forum.None. Explicit call to Content.equals(entityName) method can be rewritten as (Content == (entityName))

ExplicitCallToEqualsMethod2107

[SRC]if ("add".equals(mode)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.forum.None. Explicit call to add.equals(mode) method can be rewritten as (add == (mode))

ExplicitCallToEqualsMethod2119

[SRC]if ("Content".equals(currentValue?.getEntityName())) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.forum.None. Explicit call to Content.equals(currentValue?.getEntityName()) method can be rewritten as (Content == (currentValue?.getEntityName()))

ExplicitCallToEqualsMethod2133

[SRC]if ("granted".equals(permissionStatus)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.forum.None. Explicit call to granted.equals(permissionStatus) method can be rewritten as (granted == (permissionStatus))

UnnecessaryGroovyImport321

[SRC]import java.util.ArrayList

UnusedImport321

[SRC]import java.util.ArrayList

[MSG]The [java.util.ArrayList] import is never referenced

UnnecessaryGroovyImport322

[SRC]import java.util.Collection

UnusedImport322

[SRC]import java.util.Collection

[MSG]The [java.util.Collection] import is never referenced

UnnecessaryGroovyImport323

[SRC]import java.util.HashMap

UnusedImport323

[SRC]import java.util.HashMap

[MSG]The [java.util.HashMap] import is never referenced

UnnecessaryGroovyImport324

[SRC]import java.util.Iterator

UnusedImport324

[SRC]import java.util.Iterator

[MSG]The [java.util.Iterator] import is never referenced

UnnecessaryGroovyImport325

[SRC]import java.util.LinkedList

UnusedImport325

[SRC]import java.util.LinkedList

[MSG]The [java.util.LinkedList] import is never referenced

UnnecessaryGroovyImport326

[SRC]import java.util.List

UnusedImport326

[SRC]import java.util.List

[MSG]The [java.util.List] import is never referenced

UnnecessaryGroovyImport327

[SRC]import java.util.Map

UnusedImport327

[SRC]import java.util.Map

[MSG]The [java.util.Map] import is never referenced

UnnecessaryGroovyImport328

[SRC]import java.util.Set

UnusedImport328

[SRC]import java.util.Set

[MSG]The [java.util.Set] import is never referenced

UnnecessaryGroovyImport329

[SRC]import java.util.TreeSet

UnusedImport329

[SRC]import java.util.TreeSet

[MSG]The [java.util.TreeSet] import is never referenced

NoWildcardImports331

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports332

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports333

[SRC]import org.apache.ofbiz.security.*

[MSG]Wildcard (star) import

NoWildcardImports334

[SRC]import org.apache.ofbiz.service.*

[MSG]Wildcard (star) import

NoWildcardImports335

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

UnusedImport336

[SRC]import org.apache.ofbiz.content.content.PermissionRecorder

[MSG]The [org.apache.ofbiz.content.content.PermissionRecorder] import is never referenced

NoWildcardImports339

[SRC]import javax.servlet.*

[MSG]Wildcard (star) import

NoWildcardImports340

[SRC]import javax.servlet.http.*

[MSG]Wildcard (star) import

UnnecessaryGString347

[SRC]permissionType = context.permissionType ?: "simple"

[MSG]The String 'simple' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]currentValue = request.getAttribute("currentValue")

[MSG]The String 'currentValue' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]if ("add".equals(mode)) {

[MSG]The String 'add' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]entityOperation = context.addEntityOperation ?: context...?: "_CREATE"

[MSG]The String '_CREATE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString362

[SRC]targetOperation = context.addTargetOperation ?: context...TENT_CREATE"

[MSG]The String 'targetOperation' can be wrapped in single quotes instead of double quotes

UnnecessaryGString362

[SRC]targetOperation = context.addTargetOperation ?: context...TENT_CREATE"

[MSG]The String 'CONTENT_CREATE' can be wrapped in single quotes instead of double quotes

CouldBeElvis365

[SRC]if (!entityOperation) {

[MSG]Code could use elvis operator: entityOperation = entityOperation ?: '_UPDATE'

UnnecessaryGString366

[SRC]entityOperation = "_UPDATE"

[MSG]The String '_UPDATE' can be wrapped in single quotes instead of double quotes

CouldBeElvis368

[SRC]if (!targetOperation) {

[MSG]Code could use elvis operator: targetOperation = targetOperation ?: 'CONTENT_UPDATE'

UnnecessaryGString369

[SRC]targetOperation = "CONTENT_UPDATE"

[MSG]The String 'CONTENT_UPDATE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString373

[SRC]if ("complex".equals(permissionType)) {

[MSG]The String 'complex' can be wrapped in single quotes instead of double quotes

UnnecessaryGString376

[SRC]targetOperationList = StringUtil.split(targetOperation, "|")

[MSG]The String '|' can be wrapped in single quotes instead of double quotes

UnnecessaryGString384

[SRC]if (!currentValue || !"Content".equals(entityName)) {

[MSG]The String 'Content' can be wrapped in single quotes instead of double quotes

CouldBeElvis389

[SRC]} else if (!thisContentId) {

[MSG]Code could use elvis operator: thisContentId = thisContentId ?: ContentManagementWorker.getFromSomewhere(subContentId, paramMap, request, context)

UnnecessaryGString390

[SRC]thisContentId = ContentManagementWorker.getFromSomewhere..st, context)

[MSG]The String 'subContentId' can be wrapped in single quotes instead of double quotes

CouldBeElvis391

[SRC]} else if (!thisContentId) {

[MSG]Code could use elvis operator: thisContentId = thisContentId ?: ContentManagementWorker.getFromSomewhere(contentIdTo, paramMap, request, context)

UnnecessaryGString392

[SRC]thisContentId = ContentManagementWorker.getFromSomewhere..st, context)

[MSG]The String 'contentIdTo' can be wrapped in single quotes instead of double quotes

CouldBeElvis393

[SRC]} else if (!thisContentId) {

[MSG]Code could use elvis operator: thisContentId = thisContentId ?: ContentManagementWorker.getFromSomewhere(contentId, paramMap, request, context)

UnnecessaryGString394

[SRC]thisContentId = ContentManagementWorker.getFromSomewhere..st, context)

[MSG]The String 'contentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3102

[SRC]if (!currentValue || !"Content".equals(entityName)) {

[MSG]The String 'Content' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3104

[SRC]currentValue = from("Content").where("contentId", thisCo..).queryOne()

[MSG]The String 'Content' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3104

[SRC]currentValue = from("Content").where("contentId", thisCo..).queryOne()

[MSG]The String 'contentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3107

[SRC]if ("add".equals(mode)) {

[MSG]The String 'add' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3119

[SRC]if ("Content".equals(currentValue?.getEntityName())) {

[MSG]The String 'Content' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3126

[SRC]mapIncontentPurposeList = StringUtil.split(contentPurposeTypeId, "|")

[MSG]The String '|' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3133

[SRC]if ("granted".equals(permissionStatus)) {

[MSG]The String 'granted' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3135

[SRC]request.setAttribute("hasPermission", true)

[MSG]The String 'hasPermission' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3136

[SRC]request.setAttribute("permissionStatus", "granted")

[MSG]The String 'permissionStatus' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3136

[SRC]request.setAttribute("permissionStatus", "granted")

[MSG]The String 'granted' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3139

[SRC]request.setAttribute("hasPermission", false)

[MSG]The String 'hasPermission' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3140

[SRC]request.setAttribute("permissionStatus", "")

[MSG]The String 'permissionStatus' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3140

[SRC]request.setAttribute("permissionStatus", "")

[MSG]The String '' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3141

[SRC]errorMessage = "Permission to display:" + page.getPageNa.. is denied."

[MSG]The String 'Permission to display:' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3141

[SRC]errorMessage = "Permission to display:" + page.getPageNa.. is denied."

[MSG]The String ' is denied.' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3147

[SRC]errorMessage += " \n " + permissionMessage

[MSG]The String ' \n ' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3149

[SRC]request.setAttribute("errorMsgReq", errorMessage)

[MSG]The String 'errorMsgReq' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3158

[SRC]request.setAttribute("hasPermission", true)

[MSG]The String 'hasPermission' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3159

[SRC]request.setAttribute("permissionStatus", "granted")

[MSG]The String 'permissionStatus' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3159

[SRC]request.setAttribute("permissionStatus", "granted")

[MSG]The String 'granted' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3163

[SRC]request.setAttribute("hasPermission", false)

[MSG]The String 'hasPermission' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3164

[SRC]request.setAttribute("permissionStatus", "")

[MSG]The String 'permissionStatus' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3164

[SRC]request.setAttribute("permissionStatus", "")

[MSG]The String '' can be wrapped in single quotes instead of double quotes

➥ PubInit.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGroovyImport321

[SRC]import java.util.ArrayList

UnusedImport321

[SRC]import java.util.ArrayList

[MSG]The [java.util.ArrayList] import is never referenced

UnnecessaryGroovyImport322

[SRC]import java.util.Collection

UnusedImport322

[SRC]import java.util.Collection

[MSG]The [java.util.Collection] import is never referenced

UnnecessaryGroovyImport323

[SRC]import java.util.HashMap

UnusedImport323

[SRC]import java.util.HashMap

[MSG]The [java.util.HashMap] import is never referenced

UnnecessaryGroovyImport324

[SRC]import java.util.Iterator

UnusedImport324

[SRC]import java.util.Iterator

[MSG]The [java.util.Iterator] import is never referenced

UnnecessaryGroovyImport325

[SRC]import java.util.LinkedList

UnusedImport325

[SRC]import java.util.LinkedList

[MSG]The [java.util.LinkedList] import is never referenced

UnnecessaryGroovyImport326

[SRC]import java.util.List

UnusedImport326

[SRC]import java.util.List

[MSG]The [java.util.List] import is never referenced

UnnecessaryGroovyImport327

[SRC]import java.util.Map

UnusedImport327

[SRC]import java.util.Map

[MSG]The [java.util.Map] import is never referenced

UnnecessaryGroovyImport328

[SRC]import java.util.Set

UnusedImport328

[SRC]import java.util.Set

[MSG]The [java.util.Set] import is never referenced

UnnecessaryGroovyImport329

[SRC]import java.util.TreeSet

UnusedImport329

[SRC]import java.util.TreeSet

[MSG]The [java.util.TreeSet] import is never referenced

NoWildcardImports330

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports331

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports332

[SRC]import org.apache.ofbiz.security.*

[MSG]Wildcard (star) import

NoWildcardImports333

[SRC]import org.apache.ofbiz.service.*

[MSG]Wildcard (star) import

NoWildcardImports334

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

NoWildcardImports334

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

NoWildcardImports336

[SRC]import org.apache.ofbiz.securityext.login.*

[MSG]Wildcard (star) import

NoWildcardImports337

[SRC]import org.apache.ofbiz.common.*

[MSG]Wildcard (star) import

DuplicateImport338

[SRC]import org.apache.ofbiz.entity.model.*

NoWildcardImports341

[SRC]import javax.servlet.*

[MSG]Wildcard (star) import

NoWildcardImports342

[SRC]import javax.servlet.http.*

[MSG]Wildcard (star) import

UnnecessaryGString349

[SRC]session.setAttribute("rootPubId", rootForumId)

[MSG]The String 'rootPubId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]request.setAttribute("rootPubId", rootForumId)

[MSG]The String 'rootPubId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString351

[SRC]forumId = ContentManagementWorker.getFromSomewhere("foru..st, context)

[MSG]The String 'forumId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]session.setAttribute("forumId", forumId)

[MSG]The String 'forumId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]request.setAttribute("forumId", forumId)

[MSG]The String 'forumId' can be wrapped in single quotes instead of double quotes

➥ RespondPermAndPrep.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod284

[SRC]if (!"granted".equals(permissionStatus)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.forum.None. Explicit call to granted.equals(permissionStatus) method can be rewritten as (granted == (permissionStatus))

UnnecessaryGroovyImport321

[SRC]import java.util.ArrayList

UnusedImport321

[SRC]import java.util.ArrayList

[MSG]The [java.util.ArrayList] import is never referenced

UnnecessaryGroovyImport322

[SRC]import java.util.Collection

UnusedImport322

[SRC]import java.util.Collection

[MSG]The [java.util.Collection] import is never referenced

UnnecessaryGroovyImport323

[SRC]import java.util.HashMap

UnusedImport323

[SRC]import java.util.HashMap

[MSG]The [java.util.HashMap] import is never referenced

UnnecessaryGroovyImport324

[SRC]import java.util.Iterator

UnusedImport324

[SRC]import java.util.Iterator

[MSG]The [java.util.Iterator] import is never referenced

UnnecessaryGroovyImport325

[SRC]import java.util.LinkedList

UnusedImport325

[SRC]import java.util.LinkedList

[MSG]The [java.util.LinkedList] import is never referenced

UnnecessaryGroovyImport326

[SRC]import java.util.List

UnusedImport326

[SRC]import java.util.List

[MSG]The [java.util.List] import is never referenced

UnnecessaryGroovyImport327

[SRC]import java.util.Map

UnusedImport327

[SRC]import java.util.Map

[MSG]The [java.util.Map] import is never referenced

UnnecessaryGroovyImport328

[SRC]import java.util.Set

UnusedImport328

[SRC]import java.util.Set

[MSG]The [java.util.Set] import is never referenced

UnnecessaryGroovyImport329

[SRC]import java.util.TreeSet

UnusedImport329

[SRC]import java.util.TreeSet

[MSG]The [java.util.TreeSet] import is never referenced

NoWildcardImports331

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports332

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports333

[SRC]import org.apache.ofbiz.security.*

[MSG]Wildcard (star) import

NoWildcardImports334

[SRC]import org.apache.ofbiz.service.*

[MSG]Wildcard (star) import

NoWildcardImports335

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

UnusedImport336

[SRC]import org.apache.ofbiz.content.content.PermissionRecorder

[MSG]The [org.apache.ofbiz.content.content.PermissionRecorder] import is never referenced

NoWildcardImports338

[SRC]import javax.servlet.*

[MSG]Wildcard (star) import

NoWildcardImports339

[SRC]import javax.servlet.http.*

[MSG]Wildcard (star) import

UnnecessaryGString345

[SRC]request.setAttribute("errorMsgReq", "contentIdTo is empty")

[MSG]The String 'errorMsgReq' can be wrapped in single quotes instead of double quotes

UnnecessaryGString345

[SRC]request.setAttribute("errorMsgReq", "contentIdTo is empty")

[MSG]The String 'contentIdTo is empty' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]contentToValue = from("Content").where("contentId", cont..).queryOne()

[MSG]The String 'Content' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]contentToValue = from("Content").where("contentId", cont..).queryOne()

[MSG]The String 'contentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString358

[SRC]contentToPurposeList = contentToValue.getRelated("Conten.. null, true)

[MSG]The String 'ContentPurpose' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon359

[SRC]currentValue = makeValue("Content", [contentTypeId : "DO..d : "_00_"])

[MSG]The colon for the literal Map entry for key [contentTypeId] within class org.apache.ofbiz.ecommerce.forum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon359

[SRC]currentValue = makeValue("Content", [contentTypeId : "DO..d : "_00_"])

[MSG]The colon for the literal Map entry for key [statusId] within class org.apache.ofbiz.ecommerce.forum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon359

[SRC]currentValue = makeValue("Content", [contentTypeId : "DO..d : "_00_"])

[MSG]The colon for the literal Map entry for key [privilegeEnumId] within class org.apache.ofbiz.ecommerce.forum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString359

[SRC]currentValue = makeValue("Content", [contentTypeId : "DO..d : "_00_"])

[MSG]The String 'Content' can be wrapped in single quotes instead of double quotes

UnnecessaryGString359

[SRC]currentValue = makeValue("Content", [contentTypeId : "DO..d : "_00_"])

[MSG]The String 'DOCUMENT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString359

[SRC]currentValue = makeValue("Content", [contentTypeId : "DO..d : "_00_"])

[MSG]The String 'CTNT_PUBLISHED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString359

[SRC]currentValue = makeValue("Content", [contentTypeId : "DO..d : "_00_"])

[MSG]The String '_00_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]if (contentToPurposeList.contains("RESPONSE")) {

[MSG]The String 'RESPONSE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString371

[SRC]targetOperationList = StringUtil.split(context.targetOperation, "|")

[MSG]The String '|' can be wrapped in single quotes instead of double quotes

UnnecessaryGString377

[SRC]mapIn.entityOperation = "_CREATE"

[MSG]The String '_CREATE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString378

[SRC]mapIn.contentPurposeList = ["RESPONSE"]

[MSG]The String 'RESPONSE' can be wrapped in single quotes instead of double quotes

InvertedIfElse384

[SRC]if (!"granted".equals(permissionStatus)) {

[MSG]Testing the negative condition first can make an if statement confusing

UnnecessaryGString384

[SRC]if (!"granted".equals(permissionStatus)) {

[MSG]The String 'granted' can be wrapped in single quotes instead of double quotes

UnnecessaryGString385

[SRC]request.setAttribute("errorMsgReq", "Permission to add r..denied (1)")

[MSG]The String 'errorMsgReq' can be wrapped in single quotes instead of double quotes

UnnecessaryGString385

[SRC]request.setAttribute("errorMsgReq", "Permission to add r..denied (1)")

[MSG]The String 'Permission to add response is denied (1)' can be wrapped in single quotes instead of double quotes

UnnecessaryGString386

[SRC]errorMessage = "Permission to add response is denied (2)"

[MSG]The String 'Permission to add response is denied (2)' can be wrapped in single quotes instead of double quotes

UnnecessaryGString392

[SRC]errorMessage += " \n " + permissionMessage

[MSG]The String ' \n ' can be wrapped in single quotes instead of double quotes

UnnecessaryGString394

[SRC]request.setAttribute("permissionErrorMsg", errorMessage)

[MSG]The String 'permissionErrorMsg' can be wrapped in single quotes instead of double quotes

UnnecessaryGString397

[SRC]request.setAttribute("hasPermission", false)

[MSG]The String 'hasPermission' can be wrapped in single quotes instead of double quotes

UnnecessaryGString398

[SRC]request.setAttribute("permissionStatus", "")

[MSG]The String 'permissionStatus' can be wrapped in single quotes instead of double quotes

UnnecessaryGString398

[SRC]request.setAttribute("permissionStatus", "")

[MSG]The String '' can be wrapped in single quotes instead of double quotes

UnnecessaryElseStatement3100

[SRC]} else {

[MSG]When an if statement block ends with a return statement the else is unnecessary

UnnecessaryGString3102

[SRC]request.setAttribute("hasPermission", true)

[MSG]The String 'hasPermission' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3103

[SRC]request.setAttribute("permissionStatus", "granted")

[MSG]The String 'permissionStatus' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3103

[SRC]request.setAttribute("permissionStatus", "granted")

[MSG]The String 'granted' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3140

[SRC]request.setAttribute("currentValue", currentValue)

[MSG]The String 'currentValue' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3142

[SRC]singleWrapper.putInContext("contentPurposeTypeId", conte..rposeTypeId)

[MSG]The String 'contentPurposeTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3143

[SRC]singleWrapper.putInContext("targetOperation", context.targetOperation)

[MSG]The String 'targetOperation' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3144

[SRC]singleWrapper.putInContext("targetOperationString", cont..etOperation)

[MSG]The String 'targetOperationString' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3145

[SRC]singleWrapper.putInContext("currentValue", currentValue)

[MSG]The String 'currentValue' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3150

[SRC]idNamePair = trailList[trailList.size() -1]

[MSG]The operator "-" within class org.apache.ofbiz.ecommerce.forum.None is not followed by a space or whitespace

UnnecessaryCallForLastElement3150

[SRC]idNamePair = trailList[trailList.size() -1]

[MSG]Unnecessarily complex access of last element. This can be simplified to trailList.last() or trailList[-1]

UnnecessaryGString3152

[SRC]if (!replyName.contains("RE:")) {

[MSG]The String 'RE:' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3153

[SRC]replyName = "RE:" + replyName

[MSG]The String 'RE:' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon3156

[SRC]singleWrapper.putInContext("replyName", [contentName : r.. replyName])

[MSG]The colon for the literal Map entry for key [contentName] within class org.apache.ofbiz.ecommerce.forum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3156

[SRC]singleWrapper.putInContext("replyName", [contentName : r.. replyName])

[MSG]The colon for the literal Map entry for key [description] within class org.apache.ofbiz.ecommerce.forum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3156

[SRC]singleWrapper.putInContext("replyName", [contentName : r.. replyName])

[MSG]The String 'replyName' can be wrapped in single quotes instead of double quotes

➥ ResponsePrep.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGroovyImport321

[SRC]import java.util.ArrayList

UnusedImport321

[SRC]import java.util.ArrayList

[MSG]The [java.util.ArrayList] import is never referenced

UnnecessaryGroovyImport322

[SRC]import java.util.Collection

UnusedImport322

[SRC]import java.util.Collection

[MSG]The [java.util.Collection] import is never referenced

UnnecessaryGroovyImport323

[SRC]import java.util.HashMap

UnusedImport323

[SRC]import java.util.HashMap

[MSG]The [java.util.HashMap] import is never referenced

UnnecessaryGroovyImport324

[SRC]import java.util.Iterator

UnusedImport324

[SRC]import java.util.Iterator

[MSG]The [java.util.Iterator] import is never referenced

UnnecessaryGroovyImport325

[SRC]import java.util.LinkedList

UnusedImport325

[SRC]import java.util.LinkedList

[MSG]The [java.util.LinkedList] import is never referenced

UnnecessaryGroovyImport326

[SRC]import java.util.List

UnusedImport326

[SRC]import java.util.List

[MSG]The [java.util.List] import is never referenced

UnnecessaryGroovyImport327

[SRC]import java.util.Map

UnusedImport327

[SRC]import java.util.Map

[MSG]The [java.util.Map] import is never referenced

UnnecessaryGroovyImport328

[SRC]import java.util.Set

UnusedImport328

[SRC]import java.util.Set

[MSG]The [java.util.Set] import is never referenced

UnnecessaryGroovyImport329

[SRC]import java.util.TreeSet

UnusedImport329

[SRC]import java.util.TreeSet

[MSG]The [java.util.TreeSet] import is never referenced

NoWildcardImports331

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports332

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports333

[SRC]import org.apache.ofbiz.security.*

[MSG]Wildcard (star) import

NoWildcardImports334

[SRC]import org.apache.ofbiz.service.*

[MSG]Wildcard (star) import

NoWildcardImports335

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

NoWildcardImports336

[SRC]import org.apache.ofbiz.securityext.login.*

[MSG]Wildcard (star) import

NoWildcardImports337

[SRC]import org.apache.ofbiz.common.*

[MSG]Wildcard (star) import

NoWildcardImports340

[SRC]import javax.servlet.*

[MSG]Wildcard (star) import

NoWildcardImports341

[SRC]import javax.servlet.http.*

[MSG]Wildcard (star) import

UnnecessaryGString353

[SRC]trail = StringUtil.split(nodeTrailCsv, ",")

[MSG]The String ',' can be wrapped in single quotes instead of double quotes

UnnecessaryGString358

[SRC]ContentWorker.getContentAncestry(delegator, pubPt, "SUBS..To", idList)

[MSG]The String 'SUBSITE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString358

[SRC]ContentWorker.getContentAncestry(delegator, pubPt, "SUBS..To", idList)

[MSG]The String 'To' can be wrapped in single quotes instead of double quotes

UnnecessaryGString364

[SRC]webSitePublishPoint = from("WebSitePublishPoint").where(..).queryOne()

[MSG]The String 'WebSitePublishPoint' can be wrapped in single quotes instead of double quotes

UnnecessaryGString364

[SRC]webSitePublishPoint = from("WebSitePublishPoint").where(..).queryOne()

[MSG]The String 'contentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString372

[SRC]singleWrapper.putInContext("contentIdTo", contentIdTo)

[MSG]The String 'contentIdTo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString373

[SRC]singleWrapper.putInContext("summaryDataResourceTypeId", null)

[MSG]The String 'summaryDataResourceTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString374

[SRC]singleWrapper.putInContext("mapKey", null)

[MSG]The String 'mapKey' can be wrapped in single quotes instead of double quotes

UnnecessaryGString375

[SRC]singleWrapper.putInContext("nodeTrailCsv", nodeTrailCsv)

[MSG]The String 'nodeTrailCsv' can be wrapped in single quotes instead of double quotes

➥ ShowForum.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.ecommerce.forum.ForumEvents

SpaceAfterComma326

[SRC]context.put("viewSize",result.get("viewSize"))

[MSG]The parameter result.get(viewSize) in the call to method put within class org.apache.ofbiz.ecommerce.forum.None is not preceded by a space or whitespace

UnnecessaryGString326

[SRC]context.put("viewSize",result.get("viewSize"))

[MSG]The String 'viewSize' can be wrapped in single quotes instead of double quotes

UnnecessaryGString326

[SRC]context.put("viewSize",result.get("viewSize"))

[MSG]The String 'viewSize' can be wrapped in single quotes instead of double quotes

UnnecessaryGString327

[SRC]context.put("forumMessages", result.get("forumMessages"))

[MSG]The String 'forumMessages' can be wrapped in single quotes instead of double quotes

UnnecessaryGString327

[SRC]context.put("forumMessages", result.get("forumMessages"))

[MSG]The String 'forumMessages' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]context.put("viewIndex", result.get("viewIndex"))

[MSG]The String 'viewIndex' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]context.put("viewIndex", result.get("viewIndex"))

[MSG]The String 'viewIndex' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]context.put("listSize", result.get("listSize"))

[MSG]The String 'listSize' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]context.put("listSize", result.get("listSize"))

[MSG]The String 'listSize' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]context.put("lowIndex", result.get("lowIndex"))

[MSG]The String 'lowIndex' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]context.put("lowIndex", result.get("lowIndex"))

[MSG]The String 'lowIndex' can be wrapped in single quotes instead of double quotes

UnnecessaryGString331

[SRC]context.put("highIndex", result.get("highIndex"))

[MSG]The String 'highIndex' can be wrapped in single quotes instead of double quotes

UnnecessaryGString331

[SRC]context.put("highIndex", result.get("highIndex"))

[MSG]The String 'highIndex' can be wrapped in single quotes instead of double quotes

➥ ViewPrep.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGroovyImport321

[SRC]import java.util.ArrayList

UnusedImport321

[SRC]import java.util.ArrayList

[MSG]The [java.util.ArrayList] import is never referenced

UnnecessaryGroovyImport322

[SRC]import java.util.Collection

UnusedImport322

[SRC]import java.util.Collection

[MSG]The [java.util.Collection] import is never referenced

UnnecessaryGroovyImport323

[SRC]import java.util.HashMap

UnusedImport323

[SRC]import java.util.HashMap

[MSG]The [java.util.HashMap] import is never referenced

UnnecessaryGroovyImport324

[SRC]import java.util.Iterator

UnusedImport324

[SRC]import java.util.Iterator

[MSG]The [java.util.Iterator] import is never referenced

UnnecessaryGroovyImport325

[SRC]import java.util.LinkedList

UnusedImport325

[SRC]import java.util.LinkedList

[MSG]The [java.util.LinkedList] import is never referenced

UnnecessaryGroovyImport326

[SRC]import java.util.List

UnusedImport326

[SRC]import java.util.List

[MSG]The [java.util.List] import is never referenced

UnnecessaryGroovyImport327

[SRC]import java.util.Map

UnusedImport327

[SRC]import java.util.Map

[MSG]The [java.util.Map] import is never referenced

UnnecessaryGroovyImport328

[SRC]import java.util.Set

UnusedImport328

[SRC]import java.util.Set

[MSG]The [java.util.Set] import is never referenced

UnnecessaryGroovyImport329

[SRC]import java.util.TreeSet

UnusedImport329

[SRC]import java.util.TreeSet

[MSG]The [java.util.TreeSet] import is never referenced

NoWildcardImports331

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports332

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports333

[SRC]import org.apache.ofbiz.security.*

[MSG]Wildcard (star) import

NoWildcardImports334

[SRC]import org.apache.ofbiz.service.*

[MSG]Wildcard (star) import

NoWildcardImports335

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

NoWildcardImports336

[SRC]import org.apache.ofbiz.securityext.login.*

[MSG]Wildcard (star) import

NoWildcardImports337

[SRC]import org.apache.ofbiz.common.*

[MSG]Wildcard (star) import

UnusedImport338

[SRC]import org.apache.ofbiz.content.content.ContentWorker

[MSG]The [org.apache.ofbiz.content.content.ContentWorker] import is never referenced

NoWildcardImports341

[SRC]import javax.servlet.*

[MSG]Wildcard (star) import

NoWildcardImports342

[SRC]import javax.servlet.http.*

[MSG]Wildcard (star) import

UnnecessaryGString364

[SRC]nodeTrailCsv = ContentManagementWorker.getFromSomewhere(..st, context)

[MSG]The String 'nodeTrailCsv' can be wrapped in single quotes instead of double quotes

UnnecessaryGString366

[SRC]contentId = ContentManagementWorker.getFromSomewhere("co..st, context)

[MSG]The String 'contentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString370

[SRC]forumId = ContentManagementWorker.getFromSomewhere("foru..st, context)

[MSG]The String 'forumId' can be wrapped in single quotes instead of double quotes

Package: org.apache.ofbiz.ecommerce.includes

➥ MruAdd.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGroovyImport321

[SRC]import java.util.ArrayList

UnusedImport321

[SRC]import java.util.ArrayList

[MSG]The [java.util.ArrayList] import is never referenced

UnnecessaryGroovyImport322

[SRC]import java.util.Collection

UnusedImport322

[SRC]import java.util.Collection

[MSG]The [java.util.Collection] import is never referenced

UnnecessaryGroovyImport323

[SRC]import java.util.HashMap

UnusedImport323

[SRC]import java.util.HashMap

[MSG]The [java.util.HashMap] import is never referenced

UnnecessaryGroovyImport324

[SRC]import java.util.Iterator

UnusedImport324

[SRC]import java.util.Iterator

[MSG]The [java.util.Iterator] import is never referenced

UnnecessaryGroovyImport325

[SRC]import java.util.LinkedList

UnusedImport325

[SRC]import java.util.LinkedList

[MSG]The [java.util.LinkedList] import is never referenced

UnnecessaryGroovyImport326

[SRC]import java.util.List

UnusedImport326

[SRC]import java.util.List

[MSG]The [java.util.List] import is never referenced

UnnecessaryGroovyImport327

[SRC]import java.util.Map

UnusedImport327

[SRC]import java.util.Map

[MSG]The [java.util.Map] import is never referenced

UnnecessaryGroovyImport328

[SRC]import java.util.Set

UnusedImport328

[SRC]import java.util.Set

[MSG]The [java.util.Set] import is never referenced

UnnecessaryGroovyImport329

[SRC]import java.util.TreeSet

UnusedImport329

[SRC]import java.util.TreeSet

[MSG]The [java.util.TreeSet] import is never referenced

NoWildcardImports331

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports332

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports333

[SRC]import org.apache.ofbiz.security.*

[MSG]Wildcard (star) import

NoWildcardImports334

[SRC]import org.apache.ofbiz.service.*

[MSG]Wildcard (star) import

NoWildcardImports335

[SRC]import org.apache.ofbiz.entity.model.*

[MSG]Wildcard (star) import

NoWildcardImports340

[SRC]import javax.servlet.*

[MSG]Wildcard (star) import

NoWildcardImports341

[SRC]import javax.servlet.http.*

[MSG]Wildcard (star) import

UnnecessaryGString343

[SRC]lookupCaches = session.getAttribute("lookupCaches")

[MSG]The String 'lookupCaches' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]session.setAttribute("lookupCaches", lookupCaches)

[MSG]The String 'lookupCaches' can be wrapped in single quotes instead of double quotes

UnnecessaryGString366

[SRC]lookupCaches = session.getAttribute("lookupCaches")

[MSG]The String 'lookupCaches' can be wrapped in single quotes instead of double quotes

Package: org.apache.ofbiz.ecommerce.order

➥ AnonymousTrail.groovy

Rule NamePriorityLine #Source Line / Message
NoWildcardImports321

[SRC]import org.apache.ofbiz.order.shoppingcart.*

[MSG]Wildcard (star) import

UnnecessaryGString323

[SRC]cart = session.getAttribute("shoppingCart")

[MSG]The String 'shoppingCart' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]context.shipAddr = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]trailClassMap.shipAddr = "submenutextright"

[MSG]The String 'submenutextright' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]context.shipOptions = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]trailClassMap.shipAddr = "submenutext"

[MSG]The String 'submenutext' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]trailClassMap.shipOptions = "submenutextright"

[MSG]The String 'submenutextright' can be wrapped in single quotes instead of double quotes

UnnecessaryGString339

[SRC]context.billing = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]trailClassMap.shipOptions = "submenutext"

[MSG]The String 'submenutext' can be wrapped in single quotes instead of double quotes

UnnecessaryGString341

[SRC]trailClassMap.paymentType = "submenutextright"

[MSG]The String 'submenutextright' can be wrapped in single quotes instead of double quotes

➥ BillSettings.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod243

[SRC]if (partyId && !"_NA_".equals(partyId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to _NA_.equals(partyId) method can be rewritten as (_NA_ == (partyId))

LineLength266

[SRC]partyContactMech = from("PartyContactMech").where("party..queryFirst()

[MSG]The line exceeds 150 characters. The line is 172 characters.

ExplicitCallToEqualsMethod280

[SRC]if ("CREDIT_CARD".equals(paymentMethod.paymentMethodTypeId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to CREDIT_CARD.equals(paymentMethod.paymentMethodTypeId) method can be rewritten as (CREDIT_CARD == (paymentMethod.paymentMethodTypeId))

ExplicitCallToEqualsMethod284

[SRC]} else if ("EFT_ACCOUNT".equals(paymentMethod.paymentMethodTypeId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to EFT_ACCOUNT.equals(paymentMethod.paymentMethodTypeId) method can be rewritten as (EFT_ACCOUNT == (paymentMethod.paymentMethodTypeId))

ExplicitCallToEqualsMethod288

[SRC]} else if ("GIFT_CARD".equals(paymentMethod.paymentMethodTypeId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to GIFT_CARD.equals(paymentMethod.paymentMethodTypeId) method can be rewritten as (GIFT_CARD == (paymentMethod.paymentMethodTypeId))

NoWildcardImports321

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports322

[SRC]import org.apache.ofbiz.entity.util.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.accounting.payment.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.order.shoppingcart.*

[MSG]Wildcard (star) import

NoWildcardImports326

[SRC]import org.apache.ofbiz.party.contact.*

[MSG]Wildcard (star) import

UnnecessaryGString328

[SRC]cart = session.getAttribute("shoppingCart")

[MSG]The String 'shoppingCart' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]payType = "GC"

[MSG]The String 'GC' can be wrapped in single quotes instead of double quotes

UnnecessaryGString341

[SRC]request.removeAttribute("_EVENT_MESSAGE_")

[MSG]The String '_EVENT_MESSAGE_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]if (partyId && !"_NA_".equals(partyId)) {

[MSG]The String '_NA_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]party = from("Party").where("partyId", partyId).queryOne()

[MSG]The String 'Party' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]party = from("Party").where("partyId", partyId).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString345

[SRC]person = party.getRelatedOne("Person", false)

[MSG]The String 'Person' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]context.paymentMethodList = EntityUtil.filterByDate(part..ull, false))

[MSG]The String 'PaymentMethod' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]postalAddress = from("PostalAddress").where("contactMech..).queryOne()

[MSG]The String 'PostalAddress' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]postalAddress = from("PostalAddress").where("contactMech..).queryOne()

[MSG]The String 'contactMechId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString362

[SRC]context.useEntityFields = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString366

[SRC]partyContactMech = from("PartyContactMech").where("party..queryFirst()

[MSG]The String 'PartyContactMech' can be wrapped in single quotes instead of double quotes

UnnecessaryGString366

[SRC]partyContactMech = from("PartyContactMech").where("party..queryFirst()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString366

[SRC]partyContactMech = from("PartyContactMech").where("party..queryFirst()

[MSG]The String 'contactMechId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString366

[SRC]partyContactMech = from("PartyContactMech").where("party..queryFirst()

[MSG]The String '-fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString377

[SRC]paymentMethod = from("PaymentMethod").where("paymentMeth..).queryOne()

[MSG]The String 'PaymentMethod' can be wrapped in single quotes instead of double quotes

UnnecessaryGString377

[SRC]paymentMethod = from("PaymentMethod").where("paymentMeth..).queryOne()

[MSG]The String 'paymentMethodId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]if ("CREDIT_CARD".equals(paymentMethod.paymentMethodTypeId)) {

[MSG]The String 'CREDIT_CARD' can be wrapped in single quotes instead of double quotes

UnnecessaryGString381

[SRC]account = paymentMethod.getRelatedOne("CreditCard", false)

[MSG]The String 'CreditCard' can be wrapped in single quotes instead of double quotes

UnnecessaryGString383

[SRC]context.paymentMethodType = "CC"

[MSG]The String 'CC' can be wrapped in single quotes instead of double quotes

UnnecessaryGString384

[SRC]} else if ("EFT_ACCOUNT".equals(paymentMethod.paymentMethodTypeId)) {

[MSG]The String 'EFT_ACCOUNT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString385

[SRC]account = paymentMethod.getRelatedOne("EftAccount", false)

[MSG]The String 'EftAccount' can be wrapped in single quotes instead of double quotes

UnnecessaryGString387

[SRC]context.paymentMethodType = "EFT"

[MSG]The String 'EFT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString388

[SRC]} else if ("GIFT_CARD".equals(paymentMethod.paymentMethodTypeId)) {

[MSG]The String 'GIFT_CARD' can be wrapped in single quotes instead of double quotes

UnnecessaryGString389

[SRC]account = paymentMethod.getRelatedOne("GiftCard", false)

[MSG]The String 'GiftCard' can be wrapped in single quotes instead of double quotes

UnnecessaryGString391

[SRC]context.paymentMethodType = "GC"

[MSG]The String 'GC' can be wrapped in single quotes instead of double quotes

UnnecessaryGString393

[SRC]context.paymentMethodType = "offline"

[MSG]The String 'offline' can be wrapped in single quotes instead of double quotes

UnnecessaryGString396

[SRC]address = account.getRelatedOne("PostalAddress", false)

[MSG]The String 'PostalAddress' can be wrapped in single quotes instead of double quotes

➥ CheckoutReview.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod242

[SRC]if ("OrderAdjustment".equals(valueObj.getEntityName())) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to OrderAdjustment.equals(valueObj.getEntityName()) method can be rewritten as (OrderAdjustment == (valueObj.getEntityName()))

ExplicitCallToEqualsMethod277

[SRC]isDemoStore = !"N".equals(productStore.isDemoStore)

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to N.equals(productStore.isDemoStore) method can be rewritten as (N == (productStore.isDemoStore))

IfStatementBraces282

[SRC]if (paymentAddress) context.paymentAddress = paymentAddress

[MSG]The if statement lacks braces

IfStatementBraces2101

[SRC]if (shipmentMethodType) context.shipMethDescription = sh...description

[MSG]The if statement lacks braces

NoWildcardImports321

[SRC]import java.lang.*

[MSG]Wildcard (star) import

UnnecessaryGroovyImport321

[SRC]import java.lang.*

NoWildcardImports322

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.accounting.payment.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.order.order.*

[MSG]Wildcard (star) import

NoWildcardImports326

[SRC]import org.apache.ofbiz.party.contact.*

[MSG]Wildcard (star) import

NoWildcardImports327

[SRC]import org.apache.ofbiz.product.catalog.*

[MSG]Wildcard (star) import

NoWildcardImports328

[SRC]import org.apache.ofbiz.product.store.*

[MSG]Wildcard (star) import

UnnecessaryGString331

[SRC]cart = session.getAttribute("shoppingCart")

[MSG]The String 'shoppingCart' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC]if ("OrderAdjustment".equals(valueObj.getEntityName())) {

[MSG]The String 'OrderAdjustment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]context.placingCustomerPerson = userLogin?.getRelatedOne..son", false)

[MSG]The String 'Person' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]paymentMethodType = from("PaymentMethodType").where("pay..).queryOne()

[MSG]The String 'PaymentMethodType' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]paymentMethodType = from("PaymentMethodType").where("pay..).queryOne()

[MSG]The String 'paymentMethodTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString377

[SRC]isDemoStore = !"N".equals(productStore.isDemoStore)

[MSG]The String 'N' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3100

[SRC]shipmentMethodType = from("ShipmentMethodType").where("s..).queryOne()

[MSG]The String 'ShipmentMethodType' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3100

[SRC]shipmentMethodType = from("ShipmentMethodType").where("s..).queryOne()

[MSG]The String 'shipmentMethodTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3110

[SRC]request.removeAttribute("_EVENT_MESSAGE_")

[MSG]The String '_EVENT_MESSAGE_' can be wrapped in single quotes instead of double quotes

➥ CheckoutShippingOptions.groovy

Rule NamePriorityLine #Source Line / Message
NoWildcardImports321

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports322

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.entity.util.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.party.contact.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.product.store.*

[MSG]Wildcard (star) import

NoWildcardImports326

[SRC]import org.apache.ofbiz.order.shoppingcart.shipping.*

[MSG]Wildcard (star) import

UnnecessaryGString328

[SRC]cart = session.getAttribute("shoppingCart")

[MSG]The String 'shoppingCart' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]party = userLogin.getRelatedOne("Party", false)

[MSG]The String 'Party' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC]context.emailList = ContactHelper.getContactMechByType(p..ESS", false)

[MSG]The String 'EMAIL_ADDRESS' can be wrapped in single quotes instead of double quotes

➥ CustSettings.groovy

Rule NamePriorityLine #Source Line / Message
LineLength237

[SRC]// NOTE: if there was an error, then don't look up and f..tomagically)

[MSG]The line exceeds 150 characters. The line is 182 characters.

LineLength272

[SRC]emailPartyContactDetail = from("PartyContactDetailByPurp..queryFirst()

[MSG]The line exceeds 150 characters. The line is 168 characters.

LineLength280

[SRC]homePhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The line exceeds 150 characters. The line is 169 characters.

LineLength290

[SRC]workPhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The line exceeds 150 characters. The line is 169 characters.

NoWildcardImports321

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

UnusedImport322

[SRC]import org.apache.ofbiz.entity.util.EntityUtil

[MSG]The [org.apache.ofbiz.entity.util.EntityUtil] import is never referenced

UnnecessaryGString338

[SRC]if (!request.getAttribute("_ERROR_MESSAGE_") && !request..E_LIST_")) {

[MSG]The String '_ERROR_MESSAGE_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]if (!request.getAttribute("_ERROR_MESSAGE_") && !request..E_LIST_")) {

[MSG]The String '_ERROR_MESSAGE_LIST_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString339

[SRC]person = from("Person").where("partyId", partyId).queryOne()

[MSG]The String 'Person' can be wrapped in single quotes instead of double quotes

UnnecessaryGString339

[SRC]person = from("Person").where("partyId", partyId).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryObjectReferences353

[SRC]parameters.occupation = person.occupation

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences354

[SRC]parameters.yearsWithEmployer = person.yearsWithEmployer

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences355

[SRC]parameters.monthsWithEmployer = person.monthsWithEmployer

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences356

[SRC]parameters.existingCustomer = person.existingCustomer

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryGString372

[SRC]emailPartyContactDetail = from("PartyContactDetailByPurp..queryFirst()

[MSG]The String 'PartyContactDetailByPurpose' can be wrapped in single quotes instead of double quotes

UnnecessaryGString372

[SRC]emailPartyContactDetail = from("PartyContactDetailByPurp..queryFirst()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString372

[SRC]emailPartyContactDetail = from("PartyContactDetailByPurp..queryFirst()

[MSG]The String 'contactMechPurposeTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString372

[SRC]emailPartyContactDetail = from("PartyContactDetailByPurp..queryFirst()

[MSG]The String 'PRIMARY_EMAIL' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]homePhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The String 'PartyContactDetailByPurpose' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]homePhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]homePhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The String 'contactMechPurposeTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]homePhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The String 'PHONE_HOME' can be wrapped in single quotes instead of double quotes

UnnecessaryGString390

[SRC]workPhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The String 'PartyContactDetailByPurpose' can be wrapped in single quotes instead of double quotes

UnnecessaryGString390

[SRC]workPhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString390

[SRC]workPhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The String 'contactMechPurposeTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString390

[SRC]workPhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The String 'PHONE_WORK' can be wrapped in single quotes instead of double quotes

➥ OptionSettings.groovy

Rule NamePriorityLine #Source Line / Message
NoWildcardImports321

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports322

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.order.shoppingcart.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.order.shoppingcart.shipping.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.party.contact.*

[MSG]Wildcard (star) import

NoWildcardImports326

[SRC]import org.apache.ofbiz.product.store.*

[MSG]Wildcard (star) import

UnnecessaryGString328

[SRC]shoppingCart = session.getAttribute("shoppingCart")

[MSG]The String 'shoppingCart' can be wrapped in single quotes instead of double quotes

UnnecessaryGString339

[SRC]request.removeAttribute("_EVENT_MESSAGE_")

[MSG]The String '_EVENT_MESSAGE_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC]partyId = session.getAttribute("orderPartyId")

[MSG]The String 'orderPartyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]party = from("Party").where("partyId", partyId).queryOne()

[MSG]The String 'Party' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]party = from("Party").where("partyId", partyId).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString348

[SRC]context.emailList = ContactHelper.getContactMechByType(..ESS", false)

[MSG]The String 'EMAIL_ADDRESS' can be wrapped in single quotes instead of double quotes

➥ OrderHistory.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod228

[SRC]if ("SUPPLIER".equals(partyRole.roleTypeId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to SUPPLIER.equals(partyRole.roleTypeId) method can be rewritten as (SUPPLIER == (partyRole.roleTypeId))

LineLength243

[SRC]downloadOrderRoleAndProductContentInfoList = from("Order...queryList()

[MSG]The line exceeds 150 characters. The line is 239 characters.

NoWildcardImports321

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports322

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.entity.util.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.entity.condition.*

[MSG]Wildcard (star) import

UnnecessaryGString326

[SRC]partyRole = from("PartyRole").where("partyId", userLogin..).queryOne()

[MSG]The String 'PartyRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString326

[SRC]partyRole = from("PartyRole").where("partyId", userLogin..).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString326

[SRC]partyRole = from("PartyRole").where("partyId", userLogin..).queryOne()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString326

[SRC]partyRole = from("PartyRole").where("partyId", userLogin..).queryOne()

[MSG]The String 'SUPPLIER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]if ("SUPPLIER".equals(partyRole.roleTypeId)) {

[MSG]The String 'SUPPLIER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]porderRoleCollection = from("OrderRole").where("partyId"...queryList()

[MSG]The String 'OrderRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]porderRoleCollection = from("OrderRole").where("partyId"...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]porderRoleCollection = from("OrderRole").where("partyId"...queryList()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]porderRoleCollection = from("OrderRole").where("partyId"...queryList()

[MSG]The String 'SUPPLIER_AGENT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString331

[SRC]porderHeaderList = EntityUtil.orderBy(EntityUtil.filterB..ion, false),

[MSG]The String 'OrderHeader' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC][EntityCondition.makeCondition("statusId", EntityOperato.._REJECTED"),

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC][EntityCondition.makeCondition("statusId", EntityOperato.._REJECTED"),

[MSG]The String 'ORDER_REJECTED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]EntityCondition.makeCondition("orderTypeId", EntityOpera..E_ORDER")]),

[MSG]The String 'orderTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]EntityCondition.makeCondition("orderTypeId", EntityOpera..E_ORDER")]),

[MSG]The String 'PURCHASE_ORDER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]["orderDate DESC"])

[MSG]The String 'orderDate DESC' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]orderRoleCollection = from("OrderRole").where("partyId",...queryList()

[MSG]The String 'OrderRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]orderRoleCollection = from("OrderRole").where("partyId",...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]orderRoleCollection = from("OrderRole").where("partyId",...queryList()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]orderRoleCollection = from("OrderRole").where("partyId",...queryList()

[MSG]The String 'PLACING_CUSTOMER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString339

[SRC]orderHeaderList = EntityUtil.orderBy(EntityUtil.filterBy..ion, false),

[MSG]The String 'OrderHeader' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC][EntityCondition.makeCondition("statusId", EntityOperato..Date DESC"])

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC][EntityCondition.makeCondition("statusId", EntityOperato..Date DESC"])

[MSG]The String 'ORDER_REJECTED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC][EntityCondition.makeCondition("statusId", EntityOperato..Date DESC"])

[MSG]The String 'orderDate DESC' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]downloadOrderRoleAndProductContentInfoList = from("Order...queryList()

[MSG]The String 'OrderRoleAndProductContentInfo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]downloadOrderRoleAndProductContentInfoList = from("Order...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]downloadOrderRoleAndProductContentInfoList = from("Order...queryList()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]downloadOrderRoleAndProductContentInfoList = from("Order...queryList()

[MSG]The String 'PLACING_CUSTOMER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]downloadOrderRoleAndProductContentInfoList = from("Order...queryList()

[MSG]The String 'productContentTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]downloadOrderRoleAndProductContentInfoList = from("Order...queryList()

[MSG]The String 'DIGITAL_DOWNLOAD' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]downloadOrderRoleAndProductContentInfoList = from("Order...queryList()

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]downloadOrderRoleAndProductContentInfoList = from("Order...queryList()

[MSG]The String 'ITEM_COMPLETED' can be wrapped in single quotes instead of double quotes

➥ OrderStatus.groovy

Rule NamePriorityLine #Source Line / Message
LineLength234

[SRC]// we have a special case here where for an anonymous or..y check here

[MSG]The line exceeds 150 characters. The line is 178 characters.

LineLength237

[SRC]// This is another special case, when Order is placed by..rder Manager

[MSG]The line exceeds 150 characters. The line is 159 characters.

LineLength248

[SRC]filteredOrderPaymentPreferences = EntityUtil.filterByCon.._OFFLINE"]))

[MSG]The line exceeds 150 characters. The line is 189 characters.

LineLength253

[SRC]filteredOrderStatusList = EntityUtil.filterByCondition(o.._CREATED"]))

[MSG]The line exceeds 150 characters. The line is 203 characters.

LineLength255

[SRC]filteredOrderStatusList = EntityUtil.filterByCondition(o..APPROVED"]))

[MSG]The line exceeds 150 characters. The line is 186 characters.

ExplicitCallToEqualsMethod263

[SRC]if ("ORDER_COMPLETED".equals(orderStatus.statusId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to ORDER_COMPLETED.equals(orderStatus.statusId) method can be rewritten as (ORDER_COMPLETED == (orderStatus.statusId))

ExplicitCallToEqualsMethod291

[SRC]if ("PURCHASE_ORDER".equals(orderHeader?.orderTypeId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to PURCHASE_ORDER.equals(orderHeader?.orderTypeId) method can be rewritten as (PURCHASE_ORDER == (orderHeader?.orderTypeId))

LineLength2101

[SRC]if (orderHeader && (!"anonymous".equals(orderHeader.crea..usView)))) {

[MSG]The line exceeds 150 characters. The line is 152 characters.

ExplicitCallToEqualsMethod2101

[SRC]if (orderHeader && (!"anonymous".equals(orderHeader.crea..usView)))) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to anonymous.equals(orderHeader.createdBy) method can be rewritten as (anonymous == (orderHeader.createdBy))

ExplicitCallToEqualsMethod2101

[SRC]if (orderHeader && (!"anonymous".equals(orderHeader.crea..usView)))) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to anonymous.equals(orderHeader.createdBy) method can be rewritten as (anonymous == (orderHeader.createdBy))

ExplicitCallToEqualsMethod2101

[SRC]if (orderHeader && (!"anonymous".equals(orderHeader.crea..usView)))) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to Y.equals(allowAnonymousView) method can be rewritten as (Y == (allowAnonymousView))

LineLength2107

[SRC]logWarning("Warning: in OrderStatus.groovy before gettin..Id")) + "]")

[MSG]The line exceeds 150 characters. The line is 237 characters.

IfStatementBraces2114

[SRC]if (productStore) isDemoStore = !"N".equals(productStore.isDemoStore)

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2114

[SRC]if (productStore) isDemoStore = !"N".equals(productStore.isDemoStore)

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to N.equals(productStore.isDemoStore) method can be rewritten as (N == (productStore.isDemoStore))

LineLength2135

[SRC]orderPaymentPreferences = EntityUtil.filterByAnd(orderHe..ANCELLED")])

[MSG]The line exceeds 150 characters. The line is 213 characters.

IfStatementBraces2151

[SRC]if (paymentAddress) context.paymentAddress = paymentAddress

[MSG]The if statement lacks braces

LineLength2154

[SRC]orderShipmentInfoSummaryList = select("shipmentId", "shi.."boxNumber")

[MSG]The line exceeds 150 characters. The line is 173 characters.

ExplicitTreeSetInstantiation2161

[SRC]customerPoNumberSet = new TreeSet()

[MSG]TreeSet objects are better instantiated using the form "[] as SortedSet"

ExplicitCallToEqualsMethod2164

[SRC]if (correspondingPoId && !"(none)".equals(correspondingPoId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to (none).equals(correspondingPoId) method can be rewritten as ((none) == (correspondingPoId))

ExplicitCallToEqualsMethod2177

[SRC]if (!"RETURN_CANCELLED".equals(rh.statusId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to RETURN_CANCELLED.equals(rh.statusId) method can be rewritten as (RETURN_CANCELLED == (rh.statusId))

UnnecessaryGroovyImport321

[SRC]import java.math.BigDecimal

UnusedImport321

[SRC]import java.math.BigDecimal

[MSG]The [java.math.BigDecimal] import is never referenced

NoWildcardImports322

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.entity.condition.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.entity.util.*

[MSG]Wildcard (star) import

NoWildcardImports326

[SRC]import org.apache.ofbiz.accounting.payment.*

[MSG]Wildcard (star) import

NoWildcardImports327

[SRC]import org.apache.ofbiz.order.order.*

[MSG]Wildcard (star) import

NoWildcardImports328

[SRC]import org.apache.ofbiz.party.contact.*

[MSG]Wildcard (star) import

NoWildcardImports329

[SRC]import org.apache.ofbiz.product.catalog.*

[MSG]Wildcard (star) import

NoWildcardImports330

[SRC]import org.apache.ofbiz.product.store.*

[MSG]Wildcard (star) import

UnnecessaryGString341

[SRC]orderHeader = from("OrderHeader").where("orderId", orderId).queryOne()

[MSG]The String 'OrderHeader' can be wrapped in single quotes instead of double quotes

UnnecessaryGString341

[SRC]orderHeader = from("OrderHeader").where("orderId", orderId).queryOne()

[MSG]The String 'orderId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC]orderStatuses = orderHeader.getRelated("OrderStatus", nu..null, false)

[MSG]The String 'OrderStatus' can be wrapped in single quotes instead of double quotes

TrailingWhitespace345

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString347

[SRC]orderPaymentPreferences = orderHeader.getRelated("OrderP..Id"), false)

[MSG]The String 'OrderPaymentPreference' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]orderPaymentPreferences = orderHeader.getRelated("OrderP..Id"), false)

[MSG]The String 'orderPaymentPreferenceId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString348

[SRC]filteredOrderPaymentPreferences = EntityUtil.filterByCon.._OFFLINE"]))

[MSG]The String 'paymentMethodTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString348

[SRC]filteredOrderPaymentPreferences = EntityUtil.filterByCon.._OFFLINE"]))

[MSG]The String 'EXT_OFFLINE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString353

[SRC]filteredOrderStatusList = EntityUtil.filterByCondition(o.._CREATED"]))

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString353

[SRC]filteredOrderStatusList = EntityUtil.filterByCondition(o.._CREATED"]))

[MSG]The String 'ORDER_COMPLETED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString353

[SRC]filteredOrderStatusList = EntityUtil.filterByCondition(o.._CREATED"]))

[MSG]The String 'ORDER_APPROVED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString353

[SRC]filteredOrderStatusList = EntityUtil.filterByCondition(o.._CREATED"]))

[MSG]The String 'ORDER_CREATED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]filteredOrderStatusList = EntityUtil.filterByCondition(o..APPROVED"]))

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]filteredOrderStatusList = EntityUtil.filterByCondition(o..APPROVED"]))

[MSG]The String 'ORDER_COMPLETED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]filteredOrderStatusList = EntityUtil.filterByCondition(o..APPROVED"]))

[MSG]The String 'ORDER_APPROVED' can be wrapped in single quotes instead of double quotes

TrailingWhitespace356

[SRC]}

[MSG]Line ends with whitespace characters

UnnecessaryGString360

[SRC]userLogin = from("UserLogin").where("userLoginId", statu..).queryOne()

[MSG]The String 'UserLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]userLogin = from("UserLogin").where("userLoginId", statu..).queryOne()

[MSG]The String 'userLoginId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]if ("ORDER_COMPLETED".equals(orderStatus.statusId)) {

[MSG]The String 'ORDER_COMPLETED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]userLogin = from("UserLogin").where("userLoginId", statu..).queryOne()

[MSG]The String 'UserLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]userLogin = from("UserLogin").where("userLoginId", statu..).queryOne()

[MSG]The String 'userLoginId' can be wrapped in single quotes instead of double quotes

CouldBeElvis380

[SRC]if (!partyId) {

[MSG]Code could use elvis operator: partyId = partyId ?: userLogin.partyId

UnnecessaryGString390

[SRC]orderHeader = from("OrderHeader").where("orderId", orderId).queryOne()

[MSG]The String 'OrderHeader' can be wrapped in single quotes instead of double quotes

UnnecessaryGString390

[SRC]orderHeader = from("OrderHeader").where("orderId", orderId).queryOne()

[MSG]The String 'orderId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString391

[SRC]if ("PURCHASE_ORDER".equals(orderHeader?.orderTypeId)) {

[MSG]The String 'PURCHASE_ORDER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString393

[SRC]roleTypeId = "SUPPLIER_AGENT"

[MSG]The String 'SUPPLIER_AGENT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString396

[SRC]roleTypeId = "PLACING_CUSTOMER"

[MSG]The String 'PLACING_CUSTOMER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3101

[SRC]if (orderHeader && (!"anonymous".equals(orderHeader.crea..usView)))) {

[MSG]The String 'anonymous' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3101

[SRC]if (orderHeader && (!"anonymous".equals(orderHeader.crea..usView)))) {

[MSG]The String 'anonymous' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3101

[SRC]if (orderHeader && (!"anonymous".equals(orderHeader.crea..usView)))) {

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3102

[SRC]orderRole = from("OrderRole").where("orderId", orderId, ..queryFirst()

[MSG]The String 'OrderRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3102

[SRC]orderRole = from("OrderRole").where("orderId", orderId, ..queryFirst()

[MSG]The String 'orderId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3102

[SRC]orderRole = from("OrderRole").where("orderId", orderId, ..queryFirst()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3102

[SRC]orderRole = from("OrderRole").where("orderId", orderId, ..queryFirst()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3105

[SRC]context.remove("orderHeader")

[MSG]The String 'orderHeader' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3107

[SRC]logWarning("Warning: in OrderStatus.groovy before gettin..Id")) + "]")

[MSG]The String 'Warning: in OrderStatus.groovy before getting order detail info: role not found or user not logged in; partyId=[' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3107

[SRC]logWarning("Warning: in OrderStatus.groovy before gettin..Id")) + "]")

[MSG]The String '], userLoginId=[' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3107

[SRC]logWarning("Warning: in OrderStatus.groovy before gettin..Id")) + "]")

[MSG]The String 'null' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3107

[SRC]logWarning("Warning: in OrderStatus.groovy before gettin..Id")) + "]")

[MSG]The String 'userLoginId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3107

[SRC]logWarning("Warning: in OrderStatus.groovy before gettin..Id")) + "]")

[MSG]The String ']' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3113

[SRC]productStore = orderHeader.getRelatedOne("ProductStore", true)

[MSG]The String 'ProductStore' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3114

[SRC]if (productStore) isDemoStore = !"N".equals(productStore.isDemoStore)

[MSG]The String 'N' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3130

[SRC]placingCustomerOrderRole = from("OrderRole").where("orde..queryFirst()

[MSG]The String 'OrderRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3130

[SRC]placingCustomerOrderRole = from("OrderRole").where("orde..queryFirst()

[MSG]The String 'orderId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3130

[SRC]placingCustomerOrderRole = from("OrderRole").where("orde..queryFirst()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3131

[SRC]placingCustomerPerson = placingCustomerOrderRole == null..).queryOne()

[MSG]The String 'Person' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3131

[SRC]placingCustomerPerson = placingCustomerOrderRole == null..).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3133

[SRC]billingAccount = orderHeader.getRelatedOne("BillingAccount", false)

[MSG]The String 'BillingAccount' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3135

[SRC]orderPaymentPreferences = EntityUtil.filterByAnd(orderHe..ANCELLED")])

[MSG]The String 'OrderPaymentPreference' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3135

[SRC]orderPaymentPreferences = EntityUtil.filterByAnd(orderHe..ANCELLED")])

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3135

[SRC]orderPaymentPreferences = EntityUtil.filterByAnd(orderHe..ANCELLED")])

[MSG]The String 'PAYMENT_CANCELLED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3138

[SRC]paymentMethod = opp.getRelatedOne("PaymentMethod", false)

[MSG]The String 'PaymentMethod' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3142

[SRC]paymentMethodType = opp.getRelatedOne("PaymentMethodType", false)

[MSG]The String 'PaymentMethodType' can be wrapped in single quotes instead of double quotes

SpaceAfterComma3154

[SRC]orderShipmentInfoSummaryList = select("shipmentId", "shi.."boxNumber")

[MSG]The parameter shipmentPackageSeqId in the call to method select within class org.apache.ofbiz.ecommerce.order.None is not preceded by a space or whitespace

SpaceAfterComma3154

[SRC]orderShipmentInfoSummaryList = select("shipmentId", "shi.."boxNumber")

[MSG]The parameter trackingCode in the call to method select within class org.apache.ofbiz.ecommerce.order.None is not preceded by a space or whitespace

SpaceAfterComma3154

[SRC]orderShipmentInfoSummaryList = select("shipmentId", "shi.."boxNumber")

[MSG]The parameter boxNumber in the call to method select within class org.apache.ofbiz.ecommerce.order.None is not preceded by a space or whitespace

UnnecessaryGString3154

[SRC]orderShipmentInfoSummaryList = select("shipmentId", "shi.."boxNumber")

[MSG]The String 'shipmentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3154

[SRC]orderShipmentInfoSummaryList = select("shipmentId", "shi.."boxNumber")

[MSG]The String 'shipmentRouteSegmentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3154

[SRC]orderShipmentInfoSummaryList = select("shipmentId", "shi.."boxNumber")

[MSG]The String 'carrierPartyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3154

[SRC]orderShipmentInfoSummaryList = select("shipmentId", "shi.."boxNumber")

[MSG]The String 'shipmentMethodTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3154

[SRC]orderShipmentInfoSummaryList = select("shipmentId", "shi.."boxNumber")

[MSG]The String 'shipmentPackageSeqId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3154

[SRC]orderShipmentInfoSummaryList = select("shipmentId", "shi.."boxNumber")

[MSG]The String 'trackingCode' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3154

[SRC]orderShipmentInfoSummaryList = select("shipmentId", "shi.."boxNumber")

[MSG]The String 'boxNumber' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3155

[SRC].from("OrderShipmentInfoSummary")

[MSG]The String 'OrderShipmentInfoSummary' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3156

[SRC].where("orderId", orderId)

[MSG]The String 'orderId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3157

[SRC].orderBy("shipmentId", "shipmentRouteSegmentId", "shipme..ckageSeqId")

[MSG]The String 'shipmentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3157

[SRC].orderBy("shipmentId", "shipmentRouteSegmentId", "shipme..ckageSeqId")

[MSG]The String 'shipmentRouteSegmentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3157

[SRC].orderBy("shipmentId", "shipmentRouteSegmentId", "shipme..ckageSeqId")

[MSG]The String 'shipmentPackageSeqId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3164

[SRC]if (correspondingPoId && !"(none)".equals(correspondingPoId)) {

[MSG]The String '(none)' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3174

[SRC]ritems = oitem.getRelated("ReturnItem", null, null, false)

[MSG]The String 'ReturnItem' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3176

[SRC]rh = ritem.getRelatedOne("ReturnHeader", false)

[MSG]The String 'ReturnHeader' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3177

[SRC]if (!"RETURN_CANCELLED".equals(rh.statusId)) {

[MSG]The String 'RETURN_CANCELLED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3184

[SRC]context.returnLink = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryObjectReferences3195

[SRC]context.headerAdjustmentsToShow = headerAdjustmentsToShow

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3196

[SRC]context.currencyUomId = orderReadHelper.getCurrency()

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3198

[SRC]context.orderShippingTotal = orderShippingTotal

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3199

[SRC]context.orderTaxTotal = orderTaxTotal

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3200

[SRC]context.orderGrandTotal = OrderReadHelper.getOrderGrandT..Adjustments)

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3201

[SRC]context.placingCustomerPerson = placingCustomerPerson

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3203

[SRC]context.billingAccount = billingAccount

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3204

[SRC]context.paymentMethods = paymentMethods

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3206

[SRC]context.productStore = productStore

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3207

[SRC]context.isDemoStore = isDemoStore

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3209

[SRC]context.orderShipmentInfoSummaryList = orderShipmentInfoSummaryList

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3210

[SRC]context.customerPoNumberSet = customerPoNumberSet

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryGString3212

[SRC]orderItemChangeReasons = from("Enumeration").where("enum...queryList()

[MSG]The String 'Enumeration' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3212

[SRC]orderItemChangeReasons = from("Enumeration").where("enum...queryList()

[MSG]The String 'enumTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3212

[SRC]orderItemChangeReasons = from("Enumeration").where("enum...queryList()

[MSG]The String 'ODR_ITM_CH_REASON' can be wrapped in single quotes instead of double quotes

➥ PaymentInformation.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod239

[SRC]if (partyId && !"_NA_".equals(partyId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to _NA_.equals(partyId) method can be rewritten as (_NA_ == (partyId))

LineLength256

[SRC]partyContactMech = from("PartyContactMech").where("party..queryFirst()

[MSG]The line exceeds 150 characters. The line is 172 characters.

ExplicitCallToEqualsMethod268

[SRC]if ("CREDIT_CARD".equals(paymentMethod?.paymentMethodTypeId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to CREDIT_CARD.equals(paymentMethod?.paymentMethodTypeId) method can be rewritten as (CREDIT_CARD == (paymentMethod?.paymentMethodTypeId))

ExplicitCallToEqualsMethod272

[SRC]} else if ("EFT_ACCOUNT".equals(paymentMethod?.paymentMethodTypeId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to EFT_ACCOUNT.equals(paymentMethod?.paymentMethodTypeId) method can be rewritten as (EFT_ACCOUNT == (paymentMethod?.paymentMethodTypeId))

ExplicitCallToEqualsMethod276

[SRC]} else if ("GIFT_CARD".equals(paymentMethod?.paymentMethodTypeId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to GIFT_CARD.equals(paymentMethod?.paymentMethodTypeId) method can be rewritten as (GIFT_CARD == (paymentMethod?.paymentMethodTypeId))

NoWildcardImports321

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports322

[SRC]import org.apache.ofbiz.entity.util.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.accounting.payment.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.order.shoppingcart.*

[MSG]Wildcard (star) import

NoWildcardImports326

[SRC]import org.apache.ofbiz.party.contact.*

[MSG]Wildcard (star) import

CouldBeElvis334

[SRC]if (!partyId) {

[MSG]Code could use elvis operator: partyId = partyId ?: userLogin.partyId

UnnecessaryGString339

[SRC]if (partyId && !"_NA_".equals(partyId)) {

[MSG]The String '_NA_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]party = from("Party").where("partyId", partyId).queryOne()

[MSG]The String 'Party' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]party = from("Party").where("partyId", partyId).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString341

[SRC]person = party.getRelatedOne("Person", false)

[MSG]The String 'Person' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]request.removeAttribute("_EVENT_MESSAGE_")

[MSG]The String '_EVENT_MESSAGE_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString351

[SRC]postalAddress = from("PostalAddress").where("contactMech..).queryOne()

[MSG]The String 'PostalAddress' can be wrapped in single quotes instead of double quotes

UnnecessaryGString351

[SRC]postalAddress = from("PostalAddress").where("contactMech..).queryOne()

[MSG]The String 'contactMechId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString352

[SRC]context.useEntityFields = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]partyContactMech = from("PartyContactMech").where("party..queryFirst()

[MSG]The String 'PartyContactMech' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]partyContactMech = from("PartyContactMech").where("party..queryFirst()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]partyContactMech = from("PartyContactMech").where("party..queryFirst()

[MSG]The String 'contactMechId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]partyContactMech = from("PartyContactMech").where("party..queryFirst()

[MSG]The String '-fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]if ("CREDIT_CARD".equals(paymentMethod?.paymentMethodTypeId)) {

[MSG]The String 'CREDIT_CARD' can be wrapped in single quotes instead of double quotes

UnnecessaryGString369

[SRC]account = paymentMethod.getRelatedOne("CreditCard", false)

[MSG]The String 'CreditCard' can be wrapped in single quotes instead of double quotes

UnnecessaryGString371

[SRC]context.paymentMethodTypeId = "CREDIT_CARD"

[MSG]The String 'CREDIT_CARD' can be wrapped in single quotes instead of double quotes

UnnecessaryGString372

[SRC]} else if ("EFT_ACCOUNT".equals(paymentMethod?.paymentMethodTypeId)) {

[MSG]The String 'EFT_ACCOUNT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString373

[SRC]account = paymentMethod.getRelatedOne("EftAccount", false)

[MSG]The String 'EftAccount' can be wrapped in single quotes instead of double quotes

UnnecessaryGString375

[SRC]context.paymentMethodTypeId = "EFT_ACCOUNT"

[MSG]The String 'EFT_ACCOUNT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString376

[SRC]} else if ("GIFT_CARD".equals(paymentMethod?.paymentMethodTypeId)) {

[MSG]The String 'GIFT_CARD' can be wrapped in single quotes instead of double quotes

UnnecessaryGString377

[SRC]account = paymentMethod.getRelatedOne("GiftCard", false)

[MSG]The String 'GiftCard' can be wrapped in single quotes instead of double quotes

UnnecessaryGString379

[SRC]context.paymentMethodTypeId = "GIFT_CARD"

[MSG]The String 'GIFT_CARD' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]context.addGiftCard = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString382

[SRC]context.paymentMethodTypeId = "EXT_OFFLINE"

[MSG]The String 'EXT_OFFLINE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString385

[SRC]address = account.getRelatedOne("PostalAddress", false)

[MSG]The String 'PostalAddress' can be wrapped in single quotes instead of double quotes

InvertedIfElse392

[SRC]if (!parameters.useShipAddr) {

[MSG]Testing the negative condition first can make an if statement confusing

UnnecessaryGString398

[SRC]context.useShipAddr = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

Indentation3116

[SRC]context.callSubmitForm = true

[MSG]The statement on line 116 in class org.apache.ofbiz.ecommerce.order.None is at the incorrect indent level: Expected column 9 but was 8

➥ PaymentOptions.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod228

[SRC]if ("GIFT_CARD".equals(paymentMethodTypeId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to GIFT_CARD.equals(paymentMethodTypeId) method can be rewritten as (GIFT_CARD == (paymentMethodTypeId))

NoWildcardImports321

[SRC]import org.apache.ofbiz.order.shoppingcart.*

[MSG]Wildcard (star) import

UnnecessaryGString328

[SRC]if ("GIFT_CARD".equals(paymentMethodTypeId)) {

[MSG]The String 'GIFT_CARD' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]context.addGiftCard = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

➥ QuickAnonCustSettings.groovy

Rule NamePriorityLine #Source Line / Message
LineLength243

[SRC]// NOTE: if there was an error, then don't look up and f..tomagically)

[MSG]The line exceeds 150 characters. The line is 182 characters.

LineLength255

[SRC]emailPartyContactDetail = from("PartyContactDetailByPurp..queryFirst()

[MSG]The line exceeds 150 characters. The line is 168 characters.

LineLength263

[SRC]homePhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The line exceeds 150 characters. The line is 169 characters.

LineLength273

[SRC]workPhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The line exceeds 150 characters. The line is 167 characters.

ExplicitCallToEqualsMethod292

[SRC]if (cartPartyId && !"_NA_".equals(cartPartyId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to _NA_.equals(cartPartyId) method can be rewritten as (_NA_ == (cartPartyId))

LineLength2103

[SRC]shippingPartyContactDetail = from("PartyContactDetailByP..queryFirst()

[MSG]The line exceeds 150 characters. The line is 166 characters.

NoWildcardImports321

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

UnusedImport322

[SRC]import org.apache.ofbiz.entity.util.EntityUtil

[MSG]The [org.apache.ofbiz.entity.util.EntityUtil] import is never referenced

NoWildcardImports323

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.entity.util.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.order.shoppingcart.*

[MSG]Wildcard (star) import

NoWildcardImports326

[SRC]import org.apache.ofbiz.party.contact.*

[MSG]Wildcard (star) import

NoWildcardImports327

[SRC]import org.apache.ofbiz.product.catalog.*

[MSG]Wildcard (star) import

UnnecessaryGString344

[SRC]if (!request.getAttribute("_ERROR_MESSAGE_") && !request..E_LIST_")) {

[MSG]The String '_ERROR_MESSAGE_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]if (!request.getAttribute("_ERROR_MESSAGE_") && !request..E_LIST_")) {

[MSG]The String '_ERROR_MESSAGE_LIST_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString345

[SRC]person = from("Person").where("partyId", partyId).queryOne()

[MSG]The String 'Person' can be wrapped in single quotes instead of double quotes

UnnecessaryGString345

[SRC]person = from("Person").where("partyId", partyId).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]emailPartyContactDetail = from("PartyContactDetailByPurp..queryFirst()

[MSG]The String 'PartyContactDetailByPurpose' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]emailPartyContactDetail = from("PartyContactDetailByPurp..queryFirst()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]emailPartyContactDetail = from("PartyContactDetailByPurp..queryFirst()

[MSG]The String 'contactMechPurposeTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]emailPartyContactDetail = from("PartyContactDetailByPurp..queryFirst()

[MSG]The String 'PRIMARY_EMAIL' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]homePhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The String 'PartyContactDetailByPurpose' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]homePhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]homePhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The String 'contactMechPurposeTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]homePhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The String 'PHONE_HOME' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon373

[SRC]workPhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.ecommerce.order.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon373

[SRC]workPhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The colon for the literal Map entry for key [contactMechPurposeTypeId] within class org.apache.ofbiz.ecommerce.order.None is not preceded by a match for regular expression [\S]

UnnecessaryGString373

[SRC]workPhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The String 'PartyContactDetailByPurpose' can be wrapped in single quotes instead of double quotes

UnnecessaryGString373

[SRC]workPhonePartyContactDetail = from("PartyContactDetailBy..queryFirst()

[MSG]The String 'PHONE_WORK' can be wrapped in single quotes instead of double quotes

UnnecessaryGString385

[SRC]cart = session.getAttribute("shoppingCart")

[MSG]The String 'shoppingCart' can be wrapped in single quotes instead of double quotes

UnnecessaryGString390

[SRC]request.removeAttribute("_EVENT_MESSAGE_")

[MSG]The String '_EVENT_MESSAGE_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString392

[SRC]if (cartPartyId && !"_NA_".equals(cartPartyId)) {

[MSG]The String '_NA_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString393

[SRC]cartParty = from("Party").where("partyId", cartPartyId).queryOne()

[MSG]The String 'Party' can be wrapped in single quotes instead of double quotes

UnnecessaryGString393

[SRC]cartParty = from("Party").where("partyId", cartPartyId).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString395

[SRC]cartPerson = cartParty.getRelatedOne("Person", false)

[MSG]The String 'Person' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3103

[SRC]shippingPartyContactDetail = from("PartyContactDetailByP..queryFirst()

[MSG]The String 'PartyContactDetailByPurpose' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3103

[SRC]shippingPartyContactDetail = from("PartyContactDetailByP..queryFirst()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3103

[SRC]shippingPartyContactDetail = from("PartyContactDetailByP..queryFirst()

[MSG]The String 'contactMechId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3118

[SRC]billingContactMechId = session.getAttribute("billingContactMechId")

[MSG]The String 'billingContactMechId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3120

[SRC]billPostalAddress = from("PostalAddress").where("contact..).queryOne()

[MSG]The String 'PostalAddress' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3120

[SRC]billPostalAddress = from("PostalAddress").where("contact..).queryOne()

[MSG]The String 'contactMechId' can be wrapped in single quotes instead of double quotes

UnnecessaryObjectReferences3129

[SRC]parameters.billToCountryGeoId = billPostalAddress.countryGeoId

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryGString3135

[SRC]context.useShippingPostalAddressForBilling = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3138

[SRC]parameters.shippingContactMechPurposeTypeId = "SHIPPING_LOCATION"

[MSG]The String 'SHIPPING_LOCATION' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3139

[SRC]parameters.billingContactMechPurposeTypeId = "BILLING_LOCATION"

[MSG]The String 'BILLING_LOCATION' can be wrapped in single quotes instead of double quotes

➥ QuickAnonOptionSettings.groovy

Rule NamePriorityLine #Source Line / Message
NoWildcardImports321

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports322

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.order.shoppingcart.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.order.shoppingcart.shipping.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.party.contact.*

[MSG]Wildcard (star) import

NoWildcardImports326

[SRC]import org.apache.ofbiz.product.store.*

[MSG]Wildcard (star) import

UnnecessaryGString328

[SRC]shoppingCart = session.getAttribute("shoppingCart")

[MSG]The String 'shoppingCart' can be wrapped in single quotes instead of double quotes

UnnecessaryGString339

[SRC]request.removeAttribute("_EVENT_MESSAGE_")

[MSG]The String '_EVENT_MESSAGE_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC]partyId = session.getAttribute("orderPartyId")

[MSG]The String 'orderPartyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]party = from("Party").where("partyId", partyId).queryOne()

[MSG]The String 'Party' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]party = from("Party").where("partyId", partyId).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString348

[SRC]context.emailList = ContactHelper.getContactMechByType(p..ESS", false)

[MSG]The String 'EMAIL_ADDRESS' can be wrapped in single quotes instead of double quotes

➥ QuickAnonPaymentInformation.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod239

[SRC]if ("CREDIT_CARD".equals(paymentMethod?.paymentMethodTypeId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to CREDIT_CARD.equals(paymentMethod?.paymentMethodTypeId) method can be rewritten as (CREDIT_CARD == (paymentMethod?.paymentMethodTypeId))

NoWildcardImports321

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports322

[SRC]import org.apache.ofbiz.entity.util.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.accounting.payment.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.order.shoppingcart.*

[MSG]Wildcard (star) import

NoWildcardImports326

[SRC]import org.apache.ofbiz.party.contact.*

[MSG]Wildcard (star) import

UnnecessaryGString331

[SRC]paymentMethodTypeId = parameters.paymentMethodTypeId ?: "CREDIT_CARD"

[MSG]The String 'CREDIT_CARD' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]request.removeAttribute("_EVENT_MESSAGE_")

[MSG]The String '_EVENT_MESSAGE_' can be wrapped in single quotes instead of double quotes

SpaceAfterOpeningBrace338

[SRC]paymentMethods.each {paymentMethod ->

[MSG]The opening brace for the closure in class org.apache.ofbiz.ecommerce.order.None is not followed by a space or whitespace

UnnecessaryGString339

[SRC]if ("CREDIT_CARD".equals(paymentMethod?.paymentMethodTypeId)) {

[MSG]The String 'CREDIT_CARD' can be wrapped in single quotes instead of double quotes

➥ RequestReturn.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitHashMapInstantiation245

[SRC]typeMap = new HashMap()

[MSG]HashMap objects are normally instantiated using the form "[:]"

NoWildcardImports321

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports322

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.party.contact.*

[MSG]Wildcard (star) import

UnnecessaryGString328

[SRC]party = userLogin.getRelatedOne("Party", false)

[MSG]The String 'Party' can be wrapped in single quotes instead of double quotes

UnnecessaryGString331

[SRC]returnTypes = from("ReturnType").orderBy("sequenceId").queryList()

[MSG]The String 'ReturnType' can be wrapped in single quotes instead of double quotes

UnnecessaryGString331

[SRC]returnTypes = from("ReturnType").orderBy("sequenceId").queryList()

[MSG]The String 'sequenceId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]returnReasons = from("ReturnReason").orderBy("sequenceId").queryList()

[MSG]The String 'ReturnReason' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]returnReasons = from("ReturnReason").orderBy("sequenceId").queryList()

[MSG]The String 'sequenceId' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon338

[SRC]returnRes = runService('getReturnableItems', [orderId : orderId])

[MSG]The colon for the literal Map entry for key [orderId] within class org.apache.ofbiz.ecommerce.order.None is not preceded by a match for regular expression [\S]

UnnecessaryGString340

[SRC]orderHeader = from("OrderHeader").where("orderId", orderId).queryOne()

[MSG]The String 'OrderHeader' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]orderHeader = from("OrderHeader").where("orderId", orderId).queryOne()

[MSG]The String 'orderId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]returnItemTypeMap = from("ReturnItemTypeMap").where("ret...queryList()

[MSG]The String 'ReturnItemTypeMap' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]returnItemTypeMap = from("ReturnItemTypeMap").where("ret...queryList()

[MSG]The String 'returnHeaderTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]returnItemTypeMap = from("ReturnItemTypeMap").where("ret...queryList()

[MSG]The String 'CUSTOMER_RETURN' can be wrapped in single quotes instead of double quotes

UnnecessaryGString351

[SRC]order = from("OrderHeader").where("orderId", orderId).queryOne()

[MSG]The String 'OrderHeader' can be wrapped in single quotes instead of double quotes

UnnecessaryGString351

[SRC]order = from("OrderHeader").where("orderId", orderId).queryOne()

[MSG]The String 'orderId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString352

[SRC]productStore = order.getRelatedOne("ProductStore", false)

[MSG]The String 'ProductStore' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]context.shippingContactMechList = ContactHelper.getConta..ESS", false)

[MSG]The String 'SHIPPING_LOCATION' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]context.shippingContactMechList = ContactHelper.getConta..ESS", false)

[MSG]The String 'POSTAL_ADDRESS' can be wrapped in single quotes instead of double quotes

➥ ShipSettings.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod235

[SRC]if (partyId && !"_NA_".equals(partyId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.order.None. Explicit call to _NA_.equals(partyId) method can be rewritten as (_NA_ == (partyId))

LineLength244

[SRC]shippingPartyContactDetail = from("PartyContactDetailByP..queryFirst()

[MSG]The line exceeds 150 characters. The line is 162 characters.

LineLength260

[SRC]// NOTE: these parameters are a special case because the..over them...

[MSG]The line exceeds 150 characters. The line is 162 characters.

NoWildcardImports321

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports322

[SRC]import org.apache.ofbiz.entity.util.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.order.shoppingcart.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.party.contact.*

[MSG]Wildcard (star) import

NoWildcardImports326

[SRC]import org.apache.ofbiz.product.catalog.*

[MSG]Wildcard (star) import

UnnecessaryGString328

[SRC]cart = session.getAttribute("shoppingCart")

[MSG]The String 'shoppingCart' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]request.removeAttribute("_EVENT_MESSAGE_")

[MSG]The String '_EVENT_MESSAGE_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]if (partyId && !"_NA_".equals(partyId)) {

[MSG]The String '_NA_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]party = from("Party").where("partyId", partyId).queryOne()

[MSG]The String 'Party' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]party = from("Party").where("partyId", partyId).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]person = party.getRelatedOne("Person", false)

[MSG]The String 'Person' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]shippingPartyContactDetail = from("PartyContactDetailByP..queryFirst()

[MSG]The String 'PartyContactDetailByPurpose' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]shippingPartyContactDetail = from("PartyContactDetailByP..queryFirst()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]shippingPartyContactDetail = from("PartyContactDetailByP..queryFirst()

[MSG]The String 'contactMechId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString351

[SRC]fullAddressBuf.append(", ")

[MSG]The String ', ' can be wrapped in single quotes instead of double quotes

UnnecessaryGString354

[SRC]fullAddressBuf.append(", ")

[MSG]The String ', ' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]fullAddressBuf.append(", ")

[MSG]The String ', ' can be wrapped in single quotes instead of double quotes

➥ ShipmentStatus.groovy

Rule NamePriorityLine #Source Line / Message
UnusedImport321

[SRC]import org.apache.ofbiz.base.util.UtilMisc

[MSG]The [org.apache.ofbiz.base.util.UtilMisc] import is never referenced

UnusedImport322

[SRC]import org.apache.ofbiz.entity.Delegator

[MSG]The [org.apache.ofbiz.entity.Delegator] import is never referenced

NoWildcardImports323

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.entity.condition.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.entity.util.*

[MSG]Wildcard (star) import

UnnecessaryGString329

[SRC]shipment = from("Shipment").where("shipmentId", shipmentId).queryOne()

[MSG]The String 'Shipment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]shipment = from("Shipment").where("shipmentId", shipmentId).queryOne()

[MSG]The String 'shipmentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]shipmentItems = from("ShipmentItem").where("shipmentId",...queryList()

[MSG]The String 'ShipmentItem' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]shipmentItems = from("ShipmentItem").where("shipmentId",...queryList()

[MSG]The String 'shipmentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]orderShipmentInfoSummaryList = select("shipmentId", "shi..ackingCode")

[MSG]The String 'shipmentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]orderShipmentInfoSummaryList = select("shipmentId", "shi..ackingCode")

[MSG]The String 'shipmentRouteSegmentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]orderShipmentInfoSummaryList = select("shipmentId", "shi..ackingCode")

[MSG]The String 'shipmentPackageSeqId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]orderShipmentInfoSummaryList = select("shipmentId", "shi..ackingCode")

[MSG]The String 'carrierPartyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]orderShipmentInfoSummaryList = select("shipmentId", "shi..ackingCode")

[MSG]The String 'trackingCode' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC].from("OrderShipmentInfoSummary")

[MSG]The String 'OrderShipmentInfoSummary' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC].where("shipmentId", shipmentId)

[MSG]The String 'shipmentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC].orderBy("shipmentId", "shipmentRouteSegmentId", "shipme..ckageSeqId")

[MSG]The String 'shipmentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC].orderBy("shipmentId", "shipmentRouteSegmentId", "shipme..ckageSeqId")

[MSG]The String 'shipmentRouteSegmentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC].orderBy("shipmentId", "shipmentRouteSegmentId", "shipme..ckageSeqId")

[MSG]The String 'shipmentPackageSeqId' can be wrapped in single quotes instead of double quotes

Package: org.apache.ofbiz.ecommerce.shoppinglist

➥ EditShoppingList.groovy

Rule NamePriorityLine #Source Line / Message
BracesForIfElse236

[SRC]if (userLogin)

[MSG]Opening brace should be on the same line as 'if'

LineLength297

[SRC]calcPriceOutMap = runService('calculateProductPrice', [p..: userLogin,

[MSG]The line exceeds 150 characters. The line is 181 characters.

ExplicitCallToEqualsMethod2102

[SRC]if ("ASSET_USAGE".equals(product.productTypeId) || "ASSE..ctTypeId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.shoppinglist.None. Explicit call to ASSET_USAGE.equals(product.productTypeId) method can be rewritten as (ASSET_USAGE == (product.productTypeId))

ExplicitCallToEqualsMethod2102

[SRC]if ("ASSET_USAGE".equals(product.productTypeId) || "ASSE..ctTypeId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.shoppinglist.None. Explicit call to ASSET_USAGE_OUT_IN.equals(product.productTypeId) method can be rewritten as (ASSET_USAGE_OUT_IN == (product.productTypeId))

ExplicitCallToEqualsMethod2132

[SRC]if ("Y".equals(product.isVirtual)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.shoppinglist.None. Explicit call to Y.equals(product.isVirtual) method can be rewritten as (Y == (product.isVirtual))

LineLength2165

[SRC]childShoppingLists = from("ShoppingList").where("partyId...queryList()

[MSG]The line exceeds 150 characters. The line is 169 characters.

LineLength2172

[SRC]childShoppingListPriceMap = runService('calculateShoppin..rencyUomId])

[MSG]The line exceeds 150 characters. The line is 254 characters.

ExplicitCallToEqualsMethod2190

[SRC]context.canView = userLogin.partyId.equals(shoppingList.partyId)

[MSG]Violation in class org.apache.ofbiz.ecommerce.shoppinglist.None. Explicit call to userLogin.partyId.equals(shoppingList.partyId) method can be rewritten as (userLogin.partyId == (shoppingList.partyId))

ExplicitCallToEqualsMethod2193

[SRC]if ("SLT_AUTO_REODR".equals(shoppingListType?.shoppingListTypeId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.shoppinglist.None. Explicit call to SLT_AUTO_REODR.equals(shoppingListType?.shoppingListTypeId) method can be rewritten as (SLT_AUTO_REODR == (shoppingListType?.shoppingListTypeId))

ExplicitCallToEqualsMethod2197

[SRC]if (userLogin.partyId.equals(shoppingList.partyId)) {

[MSG]Violation in class org.apache.ofbiz.ecommerce.shoppinglist.None. Explicit call to userLogin.partyId.equals(shoppingList.partyId) method can be rewritten as (userLogin.partyId == (shoppingList.partyId))

NoWildcardImports321

[SRC]import java.util.*

[MSG]Wildcard (star) import

UnnecessaryGroovyImport321

[SRC]import java.util.*

NoWildcardImports322

[SRC]import org.apache.ofbiz.base.util.*

[MSG]Wildcard (star) import

NoWildcardImports323

[SRC]import org.apache.ofbiz.entity.*

[MSG]Wildcard (star) import

NoWildcardImports324

[SRC]import org.apache.ofbiz.entity.util.*

[MSG]Wildcard (star) import

NoWildcardImports325

[SRC]import org.apache.ofbiz.entity.condition.*

[MSG]Wildcard (star) import

NoWildcardImports327

[SRC]import org.apache.ofbiz.order.shoppingcart.shipping.*

[MSG]Wildcard (star) import

NoWildcardImports328

[SRC]import org.apache.ofbiz.order.shoppinglist.*

[MSG]Wildcard (star) import

NoWildcardImports329

[SRC]import org.apache.ofbiz.party.contact.*

[MSG]Wildcard (star) import

NoWildcardImports330

[SRC]import org.apache.ofbiz.product.catalog.*

[MSG]Wildcard (star) import

NoWildcardImports331

[SRC]import org.apache.ofbiz.product.store.*

[MSG]Wildcard (star) import

NoWildcardImports332

[SRC]import org.apache.ofbiz.service.calendar.*

[MSG]Wildcard (star) import

UnusedImport334

[SRC]import org.apache.ofbiz.widget.renderer.VisualTheme

[MSG]The [org.apache.ofbiz.widget.renderer.VisualTheme] import is never referenced

TrailingWhitespace336

[SRC]if (userLogin)

[MSG]Line ends with whitespace characters

UnnecessaryGString338

[SRC]party = userLogin.getRelatedOne("Party", false)

[MSG]The String 'Party' can be wrapped in single quotes instead of double quotes

UnnecessaryGString354

[SRC]exprList = [EntityCondition.makeCondition("partyId", Ent..in.partyId),

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]EntityCondition.makeCondition("listName", EntityOperator..auto-save")]

[MSG]The String 'listName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]EntityCondition.makeCondition("listName", EntityOperator..auto-save")]

[MSG]The String 'auto-save' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]allShoppingLists = from("ShoppingList").where(exprList)....queryList()

[MSG]The String 'ShoppingList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]allShoppingLists = from("ShoppingList").where(exprList)....queryList()

[MSG]The String 'listName' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon358

[SRC]shoppingLists = EntityUtil.filterByAnd(allShoppingLists,..tId : null])

[MSG]The colon for the literal Map entry for key [parentShoppingListId] within class org.apache.ofbiz.ecommerce.shoppinglist.None is not preceded by a match for regular expression [\S]

UnnecessaryGString363

[SRC]shoppingListTypes = from("ShoppingListType").orderBy("de...queryList()

[MSG]The String 'ShoppingListType' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]shoppingListTypes = from("ShoppingListType").orderBy("de...queryList()

[MSG]The String 'description' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]shoppingListId = parameterMap.shoppingListId ?: request...pingListId")

[MSG]The String 'shoppingListId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]shoppingListId = parameterMap.shoppingListId ?: request...pingListId")

[MSG]The String 'currentShoppingListId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString378

[SRC]session.setAttribute("currentShoppingListId", shoppingListId)

[MSG]The String 'currentShoppingListId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString382

[SRC]shoppingList = from("ShoppingList").where("shoppingListI..).queryOne()

[MSG]The String 'ShoppingList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString382

[SRC]shoppingList = from("ShoppingList").where("shoppingListI..).queryOne()

[MSG]The String 'shoppingListId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString389

[SRC]shoppingListItems = shoppingList.getRelated("ShoppingLis.. null, true)

[MSG]The String 'ShoppingListItem' can be wrapped in single quotes instead of double quotes

UnnecessaryGString395

[SRC]product = shoppingListItem.getRelatedOne("Product", true)

[MSG]The String 'Product' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon397

[SRC]calcPriceOutMap = runService('calculateProductPrice', [p..: userLogin,

[MSG]The colon for the literal Map entry for key [product] within class org.apache.ofbiz.ecommerce.shoppinglist.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon397

[SRC]calcPriceOutMap = runService('calculateProductPrice', [p..: userLogin,

[MSG]The colon for the literal Map entry for key [quantity] within class org.apache.ofbiz.ecommerce.shoppinglist.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon397

[SRC]calcPriceOutMap = runService('calculateProductPrice', [p..: userLogin,

[MSG]The colon for the literal Map entry for key [currencyUomId] within class org.apache.ofbiz.ecommerce.shoppinglist.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon397

[SRC]calcPriceOutMap = runService('calculateProductPrice', [p..: userLogin,

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.ecommerce.shoppinglist.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3102

[SRC]if ("ASSET_USAGE".equals(product.productTypeId) || "ASSE..ctTypeId)) {

[MSG]The String 'ASSET_USAGE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3102

[SRC]if ("ASSET_USAGE".equals(product.productTypeId) || "ASSE..ctTypeId)) {

[MSG]The String 'ASSET_USAGE_OUT_IN' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3127

[SRC]totalPrice *= (rentalValue/100 * reservLength)

[MSG]The operator "/" within class org.apache.ofbiz.ecommerce.shoppinglist.None is not preceded by a space or whitespace

SpaceAroundOperator3127

[SRC]totalPrice *= (rentalValue/100 * reservLength)

[MSG]The operator "/" within class org.apache.ofbiz.ecommerce.shoppinglist.None is not followed by a space or whitespace

UnnecessaryGString3132

[SRC]if ("Y".equals(product.isVirtual)) {

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon3133

[SRC]productVariantAssocs = product.getRelated("MainProductAs..Num"], true)

[MSG]The colon for the literal Map entry for key [productAssocTypeId] within class org.apache.ofbiz.ecommerce.shoppinglist.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3133

[SRC]productVariantAssocs = product.getRelated("MainProductAs..Num"], true)

[MSG]The String 'MainProductAssoc' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3133

[SRC]productVariantAssocs = product.getRelated("MainProductAs..Num"], true)

[MSG]The String 'PRODUCT_VARIANT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3133

[SRC]productVariantAssocs = product.getRelated("MainProductAs..Num"], true)

[MSG]The String 'sequenceNum' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3146

[SRC]viewSize = parameters.VIEW_SIZE ? Integer.valueOf(parame..ewSize()?:20

[MSG]The operator "?:" within class org.apache.ofbiz.ecommerce.shoppinglist.None is not preceded by a space or whitespace

SpaceAroundOperator3146

[SRC]viewSize = parameters.VIEW_SIZE ? Integer.valueOf(parame..ewSize()?:20

[MSG]The operator "?:" within class org.apache.ofbiz.ecommerce.shoppinglist.None is not followed by a space or whitespace

UnnecessaryGString3161

[SRC]shoppingListType = shoppingList.getRelatedOne("ShoppingL..ype", false)

[MSG]The String 'ShoppingListType' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3165

[SRC]childShoppingLists = from("ShoppingList").where("partyId...queryList()

[MSG]The String 'ShoppingList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3165

[SRC]childShoppingLists = from("ShoppingList").where("partyId...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3165

[SRC]childShoppingLists = from("ShoppingList").where("partyId...queryList()

[MSG]The String 'parentShoppingListId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3165

[SRC]childShoppingLists = from("ShoppingList").where("partyId...queryList()

[MSG]The String 'listName' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon3172

[SRC]childShoppingListPriceMap = runService('calculateShoppin..rencyUomId])

[MSG]The colon for the literal Map entry for key [shoppingListId] within class org.apache.ofbiz.ecommerce.shoppinglist.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3172

[SRC]childShoppingListPriceMap = runService('calculateShoppin..rencyUomId])

[MSG]The colon for the literal Map entry for key [prodCatalogId] within class org.apache.ofbiz.ecommerce.shoppinglist.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3172

[SRC]childShoppingListPriceMap = runService('calculateShoppin..rencyUomId])

[MSG]The colon for the literal Map entry for key [webSiteId] within class org.apache.ofbiz.ecommerce.shoppinglist.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3172

[SRC]childShoppingListPriceMap = runService('calculateShoppin..rencyUomId])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.ecommerce.shoppinglist.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3172

[SRC]childShoppingListPriceMap = runService('calculateShoppin..rencyUomId])

[MSG]The colon for the literal Map entry for key [currencyUomId] within class org.apache.ofbiz.ecommerce.shoppinglist.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3187

[SRC]parentShoppingList = shoppingList.getRelatedOne("ParentS..ist", false)

[MSG]The String 'ParentShoppingList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3193

[SRC]if ("SLT_AUTO_REODR".equals(shoppingListType?.shoppingListTypeId)) {

[MSG]The String 'SLT_AUTO_REODR' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3194

[SRC]recurrenceVo = shoppingList.getRelatedOne("RecurrenceInfo", false)

[MSG]The String 'RecurrenceInfo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3201

[SRC]context.chosenShippingMethod = shoppingList.shipmentMeth..rrierPartyId

[MSG]The String '@' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3202

[SRC]context.shippingContactMechList = ContactHelper.getConta..ESS", false)

[MSG]The String 'SHIPPING_LOCATION' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3202

[SRC]context.shippingContactMechList = ContactHelper.getConta..ESS", false)

[MSG]The String 'POSTAL_ADDRESS' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3203

[SRC]context.paymentMethodList = EntityUtil.filterByDate(part..d"], false))

[MSG]The String 'PaymentMethod' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3203

[SRC]context.paymentMethodList = EntityUtil.filterByDate(part..d"], false))

[MSG]The String 'paymentMethodTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3205

[SRC]shipAddress = from("PostalAddress").where("contactMechId..).queryOne()

[MSG]The String 'PostalAddress' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3205

[SRC]shipAddress = from("PostalAddress").where("contactMechId..).queryOne()

[MSG]The String 'contactMechId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3206

[SRC]Debug.log("SL - address : " + shipAddress)

[MSG]The String 'SL - address : ' can be wrapped in single quotes instead of double quotes

CouldBeElvis3223

[SRC]if (!lastSlOrderDate) {

[MSG]Code could use elvis operator: lastSlOrderDate = lastSlOrderDate ?: recurrenceVo.startDateTime

Package: org.apache.ofbiz.example

➥ ApiTokenGenerator.groovy

Rule NamePriorityLine #Source Line / Message
SpaceAroundMapEntryColon334

[SRC]expires_in : expireTimeString,

[MSG]The colon for the literal Map entry for key [expires_in] within class org.apache.ofbiz.example.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon335

[SRC]token_type : 'Bearer',]

[MSG]The colon for the literal Map entry for key [token_type] within class org.apache.ofbiz.example.None is not preceded by a match for regular expression [\S]

➥ FindExampleFeatures.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGString326

[SRC]delegator = request.getAttribute("delegator")

[MSG]The String 'delegator' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]fieldValue = request.getParameter("exampleFeatureId")

[MSG]The String 'exampleFeatureId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString331

[SRC]andExprs.add(EntityCondition.makeCondition(EntityFunctio..eatureId")),

[MSG]The String 'exampleFeatureId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]EntityOperator.LIKE, "%" + fieldValue.toUpperCase() + "%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]EntityOperator.LIKE, "%" + fieldValue.toUpperCase() + "%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]autocompleteOptions = select("exampleFeatureId", "descri...queryList()

[MSG]The String 'exampleFeatureId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]autocompleteOptions = select("exampleFeatureId", "descri...queryList()

[MSG]The String 'description' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]autocompleteOptions = select("exampleFeatureId", "descri...queryList()

[MSG]The String 'ExampleFeature' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]autocompleteOptions = select("exampleFeatureId", "descri...queryList()

[MSG]The String '-exampleFeatureId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString339

[SRC]request.setAttribute("autocompleteOptions", autocompleteOptions)

[MSG]The String 'autocompleteOptions' can be wrapped in single quotes instead of double quotes

UnnecessaryGString341

[SRC]return "success"

[MSG]The String 'success' can be wrapped in single quotes instead of double quotes

Package: org.apache.ofbiz.lucene.content

➥ AdvancedSearchPrep.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod228

[SRC]if (!"AND".equals(searchOperator) && !"OR".equals(searchOperator)) {

[MSG]Violation in class org.apache.ofbiz.lucene.content.None. Explicit call to AND.equals(searchOperator) method can be rewritten as (AND == (searchOperator))

ExplicitCallToEqualsMethod228

[SRC]if (!"AND".equals(searchOperator) && !"OR".equals(searchOperator)) {

[MSG]Violation in class org.apache.ofbiz.lucene.content.None. Explicit call to OR.equals(searchOperator) method can be rewritten as (OR == (searchOperator))

UnnecessaryGString327

[SRC]searchOperator = request.getParameter("SEARCH_OPERATOR")

[MSG]The String 'SEARCH_OPERATOR' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]if (!"AND".equals(searchOperator) && !"OR".equals(searchOperator)) {

[MSG]The String 'AND' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]if (!"AND".equals(searchOperator) && !"OR".equals(searchOperator)) {

[MSG]The String 'OR' can be wrapped in single quotes instead of double quotes

Indentation329

[SRC]searchOperator = "OR"

[MSG]The statement on line 29 in class org.apache.ofbiz.lucene.content.None is at the incorrect indent level: Expected column 5 but was 3

UnnecessaryGString329

[SRC]searchOperator = "OR"

[MSG]The String 'OR' can be wrapped in single quotes instead of double quotes

➥ IndexProducts.groovy

Rule NamePriorityLine #Source Line / Message
AssignmentInConditional234

[SRC]while (product = products.next()) {

[MSG]Assignment used as conditional value, which always results in true. Use the == operator instead

EmptyCatchBlock245

[SRC]} catch (Exception exc) {}

[MSG]The catch block is empty

ConsecutiveBlankLines320

[MSG]File IndexProducts.groovy has consecutive blank lines

UnnecessaryGString333

[SRC]products = select("productId").from("Product").queryIterator()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]products = select("productId").from("Product").queryIterator()

[MSG]The String 'Product' can be wrapped in single quotes instead of double quotes

SpaceAfterCatch338

[SRC]} catch(Exception e) {

[MSG]The catch keyword within class org.apache.ofbiz.lucene.content.None is not followed by a single space

SpaceAfterOpeningBrace345

[SRC]} catch (Exception exc) {}

[MSG]The opening brace for the block in class org.apache.ofbiz.lucene.content.None is not followed by a space or whitespace

SpaceBeforeClosingBrace345

[SRC]} catch (Exception exc) {}

[MSG]The closing brace for the block in class org.apache.ofbiz.lucene.content.None is not preceded by a space or whitespace

UnnecessaryElseStatement350

[SRC]} else {

[MSG]When an if statement block ends with a return statement the else is unnecessary

➥ Search.groovy

Rule NamePriorityLine #Source Line / Message
ReturnNullFromCatchBlock251

[SRC]return

[MSG]Do not return null from a catch block

ExplicitCallToEqualsMethod270

[SRC]if ("any".equals(parameters.any_or_all)) {

[MSG]Violation in class org.apache.ofbiz.lucene.content.None. Explicit call to any.equals(parameters.any_or_all) method can be rewritten as (any == (parameters.any_or_all))

NoWildcardImports329

[SRC]import org.apache.lucene.search.*

[MSG]Wildcard (star) import

UnnecessaryGString346

[SRC]DirectoryReader reader = DirectoryReader.open(FSDirector..).toPath()))

[MSG]The String 'content' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]context.errorMessageList.add(UtilProperties.getMessage("..d", locale))

[MSG]The String 'ContentErrorUiLabels' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]context.errorMessageList.add(UtilProperties.getMessage("..d", locale))

[MSG]The String 'ContentSearchNotIndexed' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]QueryParser parser = new QueryParser("content", analyzer)

[MSG]The String 'content' can be wrapped in single quotes instead of double quotes

UnnecessaryGString362

[SRC]termQuery = new TermQuery(new Term("site", siteId.toString()))

[MSG]The String 'site' can be wrapped in single quotes instead of double quotes

UnnecessaryGString370

[SRC]if ("any".equals(parameters.any_or_all)) {

[MSG]The String 'any' can be wrapped in single quotes instead of double quotes

UnnecessaryGString375

[SRC]termQuery = new TermQuery(new Term("feature", searchFeature1))

[MSG]The String 'feature' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]termQuery = new TermQuery(new Term("feature", searchFeature2))

[MSG]The String 'feature' can be wrapped in single quotes instead of double quotes

UnnecessaryGString385

[SRC]termQuery = new TermQuery(new Term("feature", searchFeature3))

[MSG]The String 'feature' can be wrapped in single quotes instead of double quotes

Indentation389

[SRC]if (featureIdByType) {

[MSG]The statement on line 89 in class org.apache.ofbiz.lucene.content.None is at the incorrect indent level: Expected column 5 but was 3

Indentation390

[SRC]featureIdByType.each { key, value ->

[MSG]The statement on line 90 in class org.apache.ofbiz.lucene.content.None is at the incorrect indent level: Expected column 9 but was 5

UnnecessaryGString391

[SRC]termQuery = new TermQuery(new Term("feature", value))

[MSG]The String 'feature' can be wrapped in single quotes instead of double quotes

Indentation394

[SRC]combQuery.add(featureQuery.build(), featuresRequired)

[MSG]The statement on line 94 in class org.apache.ofbiz.lucene.content.None is at the incorrect indent level: Expected column 9 but was 5

UnnecessaryGString3106

[SRC]contentId = doc.get("contentId")

[MSG]The String 'contentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3107

[SRC]content = from("Content").where("contentId", contentId)...).queryOne()

[MSG]The String 'Content' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3107

[SRC]content = from("Content").where("contentId", contentId)...).queryOne()

[MSG]The String 'contentId' can be wrapped in single quotes instead of double quotes

➥ SearchProducts.groovy

Rule NamePriorityLine #Source Line / Message
ReturnNullFromCatchBlock247

[SRC]return

[MSG]Do not return null from a catch block

ReturnNullFromCatchBlock257

[SRC]return

[MSG]Do not return null from a catch block

ConsecutiveBlankLines320

[MSG]File SearchProducts.groovy has consecutive blank lines

UnnecessaryGString342

[SRC]DirectoryReader reader = DirectoryReader.open(FSDirector..).toPath()))

[MSG]The String 'products' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]QueryParser parser = new QueryParser("fullText", analyzer)

[MSG]The String 'fullText' can be wrapped in single quotes instead of double quotes

SpaceAfterCatch355

[SRC]} catch(ParseException pe) {

[MSG]The catch keyword within class org.apache.ofbiz.lucene.content.None is not followed by a single space

UnnecessaryGString368

[SRC]product = from("Product").where("productId", productId)...).queryOne()

[MSG]The String 'Product' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]product = from("Product").where("productId", productId)...).queryOne()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

Package: org.apache.ofbiz.manufacturing.bom

➥ BomSimulation.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.manufacturing.bom.BOMNode

Package: org.apache.ofbiz.manufacturing.jobshopmgt

➥ ProductionRunAllFixedAssets.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.manufacturing.jobshopmgt.ProductionRun

➥ ProductionRunDeclaration.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage326

[SRC]import org.apache.ofbiz.manufacturing.jobshopmgt.ProductionRun

➥ ProductionRunTaskParties.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.manufacturing.jobshopmgt.ProductionRun

➥ ProductionRunTasks.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.manufacturing.jobshopmgt.ProductionRun

➥ ViewProductionRun.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage324

[SRC]import org.apache.ofbiz.manufacturing.jobshopmgt.ProductionRun

➥ WorkWithShipmentPlans.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.manufacturing.jobshopmgt.ProductionRun

Package: org.apache.ofbiz.order.order

➥ CompanyHeader.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage330

[SRC]import org.apache.ofbiz.order.order.OrderReadHelper

➥ FilterOrderList.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.order.order.OrderReadHelper

ImportFromSamePackage323

[SRC]import org.apache.ofbiz.order.order.OrderListState

➥ OrderList.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage323

[SRC]import org.apache.ofbiz.order.order.OrderListState

➥ OrderView.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage329

[SRC]import org.apache.ofbiz.order.order.OrderReadHelper

➥ OrderViewWebSecure.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.order.order.OrderContentWrapper

➥ ViewImage.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.order.order.OrderContentWrapper

Package: org.apache.ofbiz.order.orderReturn

➥ QuickReturn.groovy

Rule NamePriorityLine #Source Line / Message
PackageName2

[MSG]package=org.apache.ofbiz.order.orderReturn

➥ ReturnHeader.groovy

Rule NamePriorityLine #Source Line / Message
PackageName2

[MSG]package=org.apache.ofbiz.order.orderReturn

➥ ReturnHistory.groovy

Rule NamePriorityLine #Source Line / Message
PackageName2

[MSG]package=org.apache.ofbiz.order.orderReturn

➥ ReturnItems.groovy

Rule NamePriorityLine #Source Line / Message
PackageName2

[MSG]package=org.apache.ofbiz.order.orderReturn

Package: org.apache.ofbiz.party.party

➥ FindMatches.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.party.party.PartyWorker

➥ PartyInvitationServices.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.party.party.PartyHelper

➥ PartyServicesScript.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage332

[SRC]import org.apache.ofbiz.party.party.PartyHelper

Package: org.apache.ofbiz.passport.login

➥ GetThirdPartyLogins.groovy

Rule NamePriorityLine #Source Line / Message
UnusedVariable224

[SRC]final String module = "GetThirdPartyLogins.groovy"

[MSG]The variable [module] in class org.apache.ofbiz.passport.login.None is not used

LineLength245

[SRC]storeLoginMethDetail = from(storeLoginMeth.loginMethType..ueryFirst();

[MSG]The line exceeds 150 characters. The line is 173 characters.

UnnecessaryGString324

[SRC]final String module = "GetThirdPartyLogins.groovy"

[MSG]The String 'GetThirdPartyLogins.groovy' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]storePassportLoginMethList = from("ThirdPartyLogin").whe..queryList();

[MSG]The String 'ThirdPartyLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]storePassportLoginMethList = from("ThirdPartyLogin").whe..queryList();

[MSG]The String 'productStoreId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]storePassportLoginMethList = from("ThirdPartyLogin").whe..queryList();

[MSG]The String 'sequenceNum ASC' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon337

[SRC]storePassportLoginMethList = from("ThirdPartyLogin").whe..queryList();

[MSG]Semicolons as line endings can be removed safely

TrailingWhitespace340

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString345

[SRC]storeLoginMethDetail = from(storeLoginMeth.loginMethType..ueryFirst();

[MSG]The String 'productStoreId' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon345

[SRC]storeLoginMethDetail = from(storeLoginMeth.loginMethType..ueryFirst();

[MSG]Semicolons as line endings can be removed safely

Package: org.apache.ofbiz.pricat.pricat

➥ FindMyExcelImport.groovy

Rule NamePriorityLine #Source Line / Message
NoWildcardImports321

[SRC]import org.apache.ofbiz.base.util.*;

[MSG]Wildcard (star) import

UnnecessarySemicolon321

[SRC]import org.apache.ofbiz.base.util.*;

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString323

[SRC]module = "FindMyExcelImport.groovy";

[MSG]The String 'FindMyExcelImport.groovy' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon323

[SRC]module = "FindMyExcelImport.groovy";

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString325

[SRC]data = from("ExcelImportHistory").where("userLoginId", u..queryList();

[MSG]The String 'ExcelImportHistory' can be wrapped in single quotes instead of double quotes

UnnecessaryGString325

[SRC]data = from("ExcelImportHistory").where("userLoginId", u..queryList();

[MSG]The String 'userLoginId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString325

[SRC]data = from("ExcelImportHistory").where("userLoginId", u..queryList();

[MSG]The String 'sequenceNum DESC' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon325

[SRC]data = from("ExcelImportHistory").where("userLoginId", u..queryList();

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon326

[SRC]context.data = data;

[MSG]Semicolons as line endings can be removed safely

➥ FindMyExcelImportLog.groovy

Rule NamePriorityLine #Source Line / Message
NoWildcardImports321

[SRC]import org.apache.ofbiz.base.util.*;

[MSG]Wildcard (star) import

UnnecessarySemicolon321

[SRC]import org.apache.ofbiz.base.util.*;

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGroovyImport322

[SRC]import java.io.FileInputStream;

UnnecessarySemicolon322

[SRC]import java.io.FileInputStream;

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString324

[SRC]module = "FindMyExcelImport.groovy";

[MSG]The String 'FindMyExcelImport.groovy' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon324

[SRC]module = "FindMyExcelImport.groovy";

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString326

[SRC]context.borderStyle = "2px inset /*begin-color ThreeDHig..nd-color*/";

[MSG]The String '2px inset /*begin-color ThreeDHighlight*/#ffffff/*end-color*/' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon326

[SRC]context.borderStyle = "2px inset /*begin-color ThreeDHig..nd-color*/";

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString327

[SRC]context.borderSimpleStyle = "2px solid /*begin-color Thr..nd-color*/";

[MSG]The String '2px solid /*begin-color ThreeDFace*/#f0f0f0/*end-color*/' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon327

[SRC]context.borderSimpleStyle = "2px solid /*begin-color Thr..nd-color*/";

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString329

[SRC]sequenceNum = request.getParameter("sequenceNum");

[MSG]The String 'sequenceNum' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon329

[SRC]sequenceNum = request.getParameter("sequenceNum");

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString332

[SRC]context.logFileContent = "No sequenceNum parameter found.";

[MSG]The String 'No sequenceNum parameter found.' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon332

[SRC]context.logFileContent = "No sequenceNum parameter found.";

[MSG]Semicolons as line endings can be removed safely

TrailingWhitespace333

[SRC]return;

[MSG]Line ends with whitespace characters

UnnecessarySemicolon333

[SRC]return;

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString336

[SRC]historyEntry = from("ExcelImportHistory").where("sequenc...queryOne();

[MSG]The String 'ExcelImportHistory' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]historyEntry = from("ExcelImportHistory").where("sequenc...queryOne();

[MSG]The String 'sequenceNum' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]historyEntry = from("ExcelImportHistory").where("sequenc...queryOne();

[MSG]The String 'userLoginId' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon336

[SRC]historyEntry = from("ExcelImportHistory").where("sequenc...queryOne();

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString338

[SRC]context.logFileContent = "No import history found.";

[MSG]The String 'No import history found.' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon338

[SRC]context.logFileContent = "No import history found.";

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon339

[SRC]return;

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString342

[SRC]logFile = FileUtil.getFile("runtime/pricat/" + userLogin..m + ".log");

[MSG]The String 'runtime/pricat/' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC]logFile = FileUtil.getFile("runtime/pricat/" + userLogin..m + ".log");

[MSG]The String '/' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC]logFile = FileUtil.getFile("runtime/pricat/" + userLogin..m + ".log");

[MSG]The String '.log' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon342

[SRC]logFile = FileUtil.getFile("runtime/pricat/" + userLogin..m + ".log");

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString344

[SRC]context.logFileContent = "No log file found.";

[MSG]The String 'No log file found.' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon344

[SRC]context.logFileContent = "No log file found.";

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon347

[SRC]FileInputStream fis = new FileInputStream(logFile);

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon348

[SRC]InputStreamReader isr = new InputStreamReader(fis);

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon349

[SRC]BufferedReader br = new BufferedReader(isr);

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString350

[SRC]logFileContent = "";

[MSG]The String '' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon350

[SRC]logFileContent = "";

[MSG]Semicolons as line endings can be removed safely

SpaceAfterWhile351

[SRC]while((s = br.readLine())!=null){

[MSG]The while keyword within class org.apache.ofbiz.pricat.pricat.None is not followed by a single space

SpaceAroundOperator351

[SRC]while((s = br.readLine())!=null){

[MSG]The operator "!=" within class org.apache.ofbiz.pricat.pricat.None is not preceded by a space or whitespace

SpaceAroundOperator351

[SRC]while((s = br.readLine())!=null){

[MSG]The operator "!=" within class org.apache.ofbiz.pricat.pricat.None is not followed by a space or whitespace

SpaceBeforeOpeningBrace351

[SRC]while((s = br.readLine())!=null){

[MSG]The opening brace for the block in class org.apache.ofbiz.pricat.pricat.None is not preceded by a space or whitespace

UnnecessarySemicolon352

[SRC]logFileContent += s;

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon354

[SRC]context.logFileContent = logFileContent;

[MSG]Semicolons as line endings can be removed safely

Package: org.apache.ofbiz.product.product.imagemanagement

➥ ImageManagementServicesScript.groovy

Rule NamePriorityLine #Source Line / Message
LineLength2258

[SRC]ScriptUtil.executeScript('component://product/src/main/g..ll, context)

[MSG]The line exceeds 150 characters. The line is 158 characters.

Package: org.apache.ofbiz.projectmgr

➥ EditWeekTimesheet.groovy

Rule NamePriorityLine #Source Line / Message
IfStatementBraces260

[SRC]if (!timesheet) return

[MSG]The if statement lacks braces

LineLength2102

[SRC]workEffortPartyAssigns = EntityUtil.filterByDate(entryWo..ull, false))

[MSG]The line exceeds 150 characters. The line is 153 characters.

ExplicitCallToEqualsMethod2107

[SRC]if ("PAS_COMPLETED".equals(workEffortPartyAssign.statusId)) {

[MSG]Violation in class org.apache.ofbiz.projectmgr.None. Explicit call to PAS_COMPLETED.equals(workEffortPartyAssign.statusId) method can be rewritten as (PAS_COMPLETED == (workEffortPartyAssign.statusId))

ExplicitCallToEqualsMethod2141

[SRC](!lastTimeEntry.workEffortId.equals(timeEntry.workEffortId) ||

[MSG]Violation in class org.apache.ofbiz.projectmgr.None. Explicit call to lastTimeEntry.workEffortId.equals(timeEntry.workEffortId) method can be rewritten as (lastTimeEntry.workEffortId == (timeEntry.workEffortId))

ExplicitCallToEqualsMethod2142

[SRC]!lastTimeEntry.rateTypeId.equals(timeEntry.rateTypeId))) {

[MSG]Violation in class org.apache.ofbiz.projectmgr.None. Explicit call to lastTimeEntry.rateTypeId.equals(timeEntry.rateTypeId) method can be rewritten as (lastTimeEntry.rateTypeId == (timeEntry.rateTypeId))

IfStatementBraces2149

[SRC]if ("d0".equals(dayNumber)) day0Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2149

[SRC]if ("d0".equals(dayNumber)) day0Total += hours

[MSG]Violation in class org.apache.ofbiz.projectmgr.None. Explicit call to d0.equals(dayNumber) method can be rewritten as (d0 == (dayNumber))

IfStatementBraces2150

[SRC]if ("d1".equals(dayNumber)) day1Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2150

[SRC]if ("d1".equals(dayNumber)) day1Total += hours

[MSG]Violation in class org.apache.ofbiz.projectmgr.None. Explicit call to d1.equals(dayNumber) method can be rewritten as (d1 == (dayNumber))

IfStatementBraces2151

[SRC]if ("d2".equals(dayNumber)) day2Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2151

[SRC]if ("d2".equals(dayNumber)) day2Total += hours

[MSG]Violation in class org.apache.ofbiz.projectmgr.None. Explicit call to d2.equals(dayNumber) method can be rewritten as (d2 == (dayNumber))

IfStatementBraces2152

[SRC]if ("d3".equals(dayNumber)) day3Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2152

[SRC]if ("d3".equals(dayNumber)) day3Total += hours

[MSG]Violation in class org.apache.ofbiz.projectmgr.None. Explicit call to d3.equals(dayNumber) method can be rewritten as (d3 == (dayNumber))

IfStatementBraces2153

[SRC]if ("d4".equals(dayNumber)) day4Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2153

[SRC]if ("d4".equals(dayNumber)) day4Total += hours

[MSG]Violation in class org.apache.ofbiz.projectmgr.None. Explicit call to d4.equals(dayNumber) method can be rewritten as (d4 == (dayNumber))

IfStatementBraces2154

[SRC]if ("d5".equals(dayNumber)) day5Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2154

[SRC]if ("d5".equals(dayNumber)) day5Total += hours

[MSG]Violation in class org.apache.ofbiz.projectmgr.None. Explicit call to d5.equals(dayNumber) method can be rewritten as (d5 == (dayNumber))

IfStatementBraces2155

[SRC]if ("d6".equals(dayNumber)) day6Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2155

[SRC]if ("d6".equals(dayNumber)) day6Total += hours

[MSG]Violation in class org.apache.ofbiz.projectmgr.None. Explicit call to d6.equals(dayNumber) method can be rewritten as (d6 == (dayNumber))

ExplicitCallToEqualsMethod2167

[SRC]if (!"TIMESHEET_COMPLETED".equals(timesheet.statusId)) {

[MSG]Violation in class org.apache.ofbiz.projectmgr.None. Explicit call to TIMESHEET_COMPLETED.equals(timesheet.statusId) method can be rewritten as (TIMESHEET_COMPLETED == (timesheet.statusId))

ExplicitLinkedListInstantiation2191

[SRC]timesheets = new LinkedList()

[MSG]LinkedList objects are better instantiated using the form "[] as Queue"

ConsecutiveBlankLines320

[MSG]File EditWeekTimesheet.groovy has consecutive blank lines

UnnecessaryGString329

[SRC]uiLabelMap = UtilProperties.getResourceBundleMap("Projec..ls", locale)

[MSG]The String 'ProjectMgrUiLabels' can be wrapped in single quotes instead of double quotes

CouldBeElvis332

[SRC]if (!partyId) {

[MSG]Code could use elvis operator: partyId = partyId ?: parameters.userLogin.partyId

UnnecessaryGString340

[SRC]timesheet = from("Timesheet").where("timesheetId", times..).queryOne()

[MSG]The String 'Timesheet' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]timesheet = from("Timesheet").where("timesheetId", times..).queryOne()

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

SpaceAfterComma344

[SRC]midweek = UtilDateTime.addDaysToTimestamp(UtilDateTime.g..estamp()),3)

[MSG]The parameter 3 in the call to method addDaysToTimestamp within class org.apache.ofbiz.projectmgr.None is not preceded by a space or whitespace

UnnecessaryGString346

[SRC]EntityCondition.makeCondition("fromDate", EntityComparis..N, midweek),

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]EntityCondition.makeCondition("thruDate", EntityComparis..N, midweek),

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString348

[SRC]EntityCondition.makeCondition("partyId", EntityCompariso..LS, partyId)

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]entryIterator = from("Timesheet").where(entryExprs).queryIterator()

[MSG]The String 'Timesheet' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon354

[SRC]result = runService('createProjectTimesheet', ["userLogi.. : partyId])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.projectmgr.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon354

[SRC]result = runService('createProjectTimesheet', ["userLogi.. : partyId])

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.projectmgr.None is not preceded by a match for regular expression [\S]

UnnecessaryGString354

[SRC]result = runService('createProjectTimesheet', ["userLogi.. : partyId])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString354

[SRC]result = runService('createProjectTimesheet', ["userLogi.. : partyId])

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]timesheet = from("Timesheet").where("timesheetId", resul..).queryOne()

[MSG]The String 'Timesheet' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]timesheet = from("Timesheet").where("timesheetId", resul..).queryOne()

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]context.partyNameView = from("PartyNameView").where("par..).queryOne()

[MSG]The String 'PartyNameView' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]context.partyNameView = from("PartyNameView").where("par..).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString367

[SRC]rateTypes = from("PartyRate").where("partyId", partyId, ...queryList()

[MSG]The String 'PartyRate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString367

[SRC]rateTypes = from("PartyRate").where("partyId", partyId, ...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString367

[SRC]rateTypes = from("PartyRate").where("partyId", partyId, ...queryList()

[MSG]The String 'defaultRate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString367

[SRC]rateTypes = from("PartyRate").where("partyId", partyId, ...queryList()

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon373

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The colon for the literal Map entry for key [timesheetId] within class org.apache.ofbiz.projectmgr.None is not preceded by a match for regular expression [\S]

UnnecessaryGString373

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator375

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.projectmgr.None is not preceded by a space or whitespace

SpaceAroundOperator375

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.projectmgr.None is not followed by a space or whitespace

SpaceAroundOperator375

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.projectmgr.None is not preceded by a space or whitespace

SpaceAroundOperator375

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.projectmgr.None is not followed by a space or whitespace

SpaceAroundOperator375

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.projectmgr.None is not preceded by a space or whitespace

SpaceAroundOperator375

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.projectmgr.None is not followed by a space or whitespace

SpaceAroundOperator375

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.projectmgr.None is not preceded by a space or whitespace

SpaceAroundOperator375

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.projectmgr.None is not followed by a space or whitespace

SpaceAroundOperator375

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.projectmgr.None is not preceded by a space or whitespace

SpaceAroundOperator375

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.projectmgr.None is not followed by a space or whitespace

SpaceAroundOperator375

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.projectmgr.None is not preceded by a space or whitespace

SpaceAroundOperator375

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.projectmgr.None is not followed by a space or whitespace

Indentation383

[SRC]entryWorkEffort = lastTimeEntry.getRelatedOne("WorkEffort", false)

[MSG]The statement on line 83 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 5 but was 9

UnnecessaryGString383

[SRC]entryWorkEffort = lastTimeEntry.getRelatedOne("WorkEffort", false)

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

Indentation384

[SRC]if (entryWorkEffort) {

[MSG]The statement on line 84 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 5 but was 9

Indentation385

[SRC]plannedHours = entryWorkEffort.getRelated("WorkEffortSki..null, false)

[MSG]The statement on line 85 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 13

UnnecessaryGString385

[SRC]plannedHours = entryWorkEffort.getRelated("WorkEffortSki..null, false)

[MSG]The String 'WorkEffortSkillStandard' can be wrapped in single quotes instead of double quotes

Indentation386

[SRC]pHours = 0.00

[MSG]The statement on line 86 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 13

Indentation387

[SRC]plannedHours.each { plannedHour ->

[MSG]The statement on line 87 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 13

Indentation392

[SRC]entry.plannedHours = pHours

[MSG]The statement on line 92 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 13

Indentation393

[SRC]actualHours = entryWorkEffort.getRelated("TimeEntry", nu..null, false)

[MSG]The statement on line 93 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 13

UnnecessaryGString393

[SRC]actualHours = entryWorkEffort.getRelated("TimeEntry", nu..null, false)

[MSG]The String 'TimeEntry' can be wrapped in single quotes instead of double quotes

Indentation394

[SRC]aHours = 0.00

[MSG]The statement on line 94 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 13

Indentation395

[SRC]actualHours.each { actualHour ->

[MSG]The statement on line 95 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3100

[SRC]entry.actualHours = aHours

[MSG]The statement on line 100 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3102

[SRC]workEffortPartyAssigns = EntityUtil.filterByDate(entryWo..ull, false))

[MSG]The statement on line 102 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 13

SpaceAroundMapEntryColon3102

[SRC]workEffortPartyAssigns = EntityUtil.filterByDate(entryWo..ull, false))

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.projectmgr.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3102

[SRC]workEffortPartyAssigns = EntityUtil.filterByDate(entryWo..ull, false))

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3102

[SRC]workEffortPartyAssigns = EntityUtil.filterByDate(entryWo..ull, false))

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

Indentation3103

[SRC]if (workEffortPartyAssigns) {

[MSG]The statement on line 103 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3104

[SRC]workEffortPartyAssign = workEffortPartyAssigns[0]

[MSG]The statement on line 104 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 13 but was 17

Indentation3105

[SRC]entry.fromDate = workEffortPartyAssign.getTimestamp("fromDate")

[MSG]The statement on line 105 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 13 but was 17

UnnecessaryGString3105

[SRC]entry.fromDate = workEffortPartyAssign.getTimestamp("fromDate")

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

Indentation3106

[SRC]entry.roleTypeId = workEffortPartyAssign.roleTypeId

[MSG]The statement on line 106 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 13 but was 17

Indentation3107

[SRC]if ("PAS_COMPLETED".equals(workEffortPartyAssign.statusId)) {

[MSG]The statement on line 107 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 13 but was 17

UnnecessaryGString3107

[SRC]if ("PAS_COMPLETED".equals(workEffortPartyAssign.statusId)) {

[MSG]The String 'PAS_COMPLETED' can be wrapped in single quotes instead of double quotes

Indentation3108

[SRC]entry.checkComplete = "Y"

[MSG]The statement on line 108 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 17 but was 21

UnnecessaryGString3108

[SRC]entry.checkComplete = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

Indentation3113

[SRC]entry.workEffortId = entryWorkEffort.workEffortId

[MSG]The statement on line 113 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3114

[SRC]entry.workEffortName = entryWorkEffort.workEffortName

[MSG]The statement on line 114 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3115

[SRC]result = runService('getProjectIdAndNameFromTask', ["use..rkEffortId])

[MSG]The statement on line 115 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 13

SpaceAfterComma3115

[SRC]result = runService('getProjectIdAndNameFromTask', ["use..rkEffortId])

[MSG]The map entry taskId:entryWorkEffort.workEffortId within class org.apache.ofbiz.projectmgr.None is not preceded by a space or whitespace

SpaceAroundMapEntryColon3115

[SRC]result = runService('getProjectIdAndNameFromTask', ["use..rkEffortId])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.projectmgr.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3115

[SRC]result = runService('getProjectIdAndNameFromTask', ["use..rkEffortId])

[MSG]The colon for the literal Map entry for key [taskId] within class org.apache.ofbiz.projectmgr.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3115

[SRC]result = runService('getProjectIdAndNameFromTask', ["use..rkEffortId])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3115

[SRC]result = runService('getProjectIdAndNameFromTask', ["use..rkEffortId])

[MSG]The String 'taskId' can be wrapped in single quotes instead of double quotes

Indentation3116

[SRC]entry.phaseId = result.phaseId

[MSG]The statement on line 116 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 17

Indentation3117

[SRC]entry.phaseName = result.phaseName

[MSG]The statement on line 117 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 17

Indentation3118

[SRC]entry.projectId = result.projectId

[MSG]The statement on line 118 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 17

Indentation3119

[SRC]entry.projectName = result.projectName

[MSG]The statement on line 119 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 17

Indentation3120

[SRC]entry.taskWbsId = result.taskWbsId

[MSG]The statement on line 120 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 17

BlockEndsWithBlankLine3121

[MSG]Code block ends with a blank line.

Indentation3123

[SRC]entry.total = taskTotal

[MSG]The statement on line 123 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 5 but was 9

Indentation3125

[SRC]entries.add(entry)

[MSG]The statement on line 125 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 5 but was 9

Indentation3127

[SRC]taskTotal = 0.00

[MSG]The statement on line 127 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 5 but was 9

Indentation3128

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The statement on line 128 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 5 but was 9

SpaceAroundMapEntryColon3128

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The colon for the literal Map entry for key [timesheetId] within class org.apache.ofbiz.projectmgr.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3128

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3131

[SRC]timeEntries = timesheet.getRelated("TimeEntry", null, ["..te"], false)

[MSG]The String 'TimeEntry' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3131

[SRC]timeEntries = timesheet.getRelated("TimeEntry", null, ["..te"], false)

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3131

[SRC]timeEntries = timesheet.getRelated("TimeEntry", null, ["..te"], false)

[MSG]The String 'rateTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3131

[SRC]timeEntries = timesheet.getRelated("TimeEntry", null, ["..te"], false)

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3135

[SRC]if (timeEntry!=void) {

[MSG]The operator "!=" within class org.apache.ofbiz.projectmgr.None is not preceded by a space or whitespace

SpaceAroundOperator3135

[SRC]if (timeEntry!=void) {

[MSG]The operator "!=" within class org.apache.ofbiz.projectmgr.None is not followed by a space or whitespace

Indentation3143

[SRC]retrieveWorkEffortData()

[MSG]The statement on line 143 in class org.apache.ofbiz.projectmgr.None is at the incorrect indent level: Expected column 9 but was 13

SpaceAroundOperator3146

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.projectmgr.None is not preceded by a space or whitespace

SpaceAroundOperator3146

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.projectmgr.None is not followed by a space or whitespace

SpaceAroundOperator3146

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.projectmgr.None is not preceded by a space or whitespace

SpaceAroundOperator3146

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.projectmgr.None is not followed by a space or whitespace

SpaceAroundOperator3146

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.projectmgr.None is not preceded by a space or whitespace

SpaceAroundOperator3146

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.projectmgr.None is not followed by a space or whitespace

UnnecessaryGString3146

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The String 'd' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3149

[SRC]if ("d0".equals(dayNumber)) day0Total += hours

[MSG]The String 'd0' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3150

[SRC]if ("d1".equals(dayNumber)) day1Total += hours

[MSG]The String 'd1' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3151

[SRC]if ("d2".equals(dayNumber)) day2Total += hours

[MSG]The String 'd2' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3152

[SRC]if ("d3".equals(dayNumber)) day3Total += hours

[MSG]The String 'd3' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3153

[SRC]if ("d4".equals(dayNumber)) day4Total += hours

[MSG]The String 'd4' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3154

[SRC]if ("d5".equals(dayNumber)) day5Total += hours

[MSG]The String 'd5' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3155

[SRC]if ("d6".equals(dayNumber)) day6Total += hours

[MSG]The String 'd6' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3167

[SRC]if (!"TIMESHEET_COMPLETED".equals(timesheet.statusId)) {

[MSG]The String 'TIMESHEET_COMPLETED' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3168

[SRC]for (c=0; c < 3; c++) { // add empty lines

[MSG]The operator "=" within class org.apache.ofbiz.projectmgr.None is not preceded by a space or whitespace

SpaceAroundOperator3168

[SRC]for (c=0; c < 3; c++) { // add empty lines

[MSG]The operator "=" within class org.apache.ofbiz.projectmgr.None is not followed by a space or whitespace

SpaceAroundMapEntryColon3169

[SRC]entries.add(["timesheetId" : timesheet.timesheetId])

[MSG]The colon for the literal Map entry for key [timesheetId] within class org.apache.ofbiz.projectmgr.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3169

[SRC]entries.add(["timesheetId" : timesheet.timesheetId])

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon3175

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The colon for the literal Map entry for key [timesheetId] within class org.apache.ofbiz.projectmgr.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3175

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3184

[SRC]entry.workEffortId = "Totals"

[MSG]The String 'Totals' can be wrapped in single quotes instead of double quotes

UnnecessaryObjectReferences3184

[SRC]entry.workEffortId = "Totals"

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3185

[SRC]entry.total = day0Total + day1Total + day2Total + day3To.. + day6Total

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryGString3190

[SRC]timesheetsDb = from("Timesheet").where("partyId", partyI...queryList()

[MSG]The String 'Timesheet' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3190

[SRC]timesheetsDb = from("Timesheet").where("partyId", partyI...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3190

[SRC]timesheetsDb = from("Timesheet").where("partyId", partyI...queryList()

[MSG]The String 'fromDate DESC' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3195

[SRC]entries = timesheetDb.getRelated("TimeEntry", null, null, false)

[MSG]The String 'TimeEntry' can be wrapped in single quotes instead of double quotes

➥ GetLastRequestAssignment.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGString324

[SRC]custRequestList = from("CustRequest").where("fromPartyId...queryList()

[MSG]The String 'CustRequest' can be wrapped in single quotes instead of double quotes

UnnecessaryGString324

[SRC]custRequestList = from("CustRequest").where("fromPartyId...queryList()

[MSG]The String 'fromPartyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString324

[SRC]custRequestList = from("CustRequest").where("fromPartyId...queryList()

[MSG]The String '-createdDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString326

[SRC]custReqTaskList = custRequestList.get(0).getRelated("Cus..null, false)

[MSG]The String 'CustRequestWorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]custReqTask = custReqTaskList.get(0).getRelatedOne("Work..se) // phase

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]projectChildWorkEffort = custReqTask.getRelatedOne("Pare../ phase name

[MSG]The String 'ParentWorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString331

[SRC]partyList = custReqTask.getRelated("WorkEffortPartyAssig..null, false)

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator334

[SRC]context.partyId= partyList.get(0).partyId

[MSG]The operator "=" within class org.apache.ofbiz.projectmgr.None is not preceded by a space or whitespace

➥ GetProjectId.groovy

Rule NamePriorityLine #Source Line / Message
UnusedImport321

[SRC]import org.apache.ofbiz.base.util.UtilValidate

[MSG]The [org.apache.ofbiz.base.util.UtilValidate] import is never referenced

UnnecessaryGString325

[SRC]projects = from("ProjectAndPhaseAndTask").where("workEff...queryList()

[MSG]The String 'ProjectAndPhaseAndTask' can be wrapped in single quotes instead of double quotes

UnnecessaryGString325

[SRC]projects = from("ProjectAndPhaseAndTask").where("workEff...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString327

[SRC]context.put("projectId", projects.get(0).getString("projectId"))

[MSG]The String 'projectId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString327

[SRC]context.put("projectId", projects.get(0).getString("projectId"))

[MSG]The String 'projectId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]context.put("projectName", projects.get(0).getString("projectName"))

[MSG]The String 'projectName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]context.put("projectName", projects.get(0).getString("projectName"))

[MSG]The String 'projectName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]context.put("phaseName", projects.get(0).getString("phaseName"))

[MSG]The String 'phaseName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]context.put("phaseName", projects.get(0).getString("phaseName"))

[MSG]The String 'phaseName' can be wrapped in single quotes instead of double quotes

➥ ListCurrentProjects.groovy

Rule NamePriorityLine #Source Line / Message
LineLength236

[SRC]resultAssign = from("WorkEffortPartyAssignment").where("...queryList()

[MSG]The line exceeds 150 characters. The line is 153 characters.

LineLength238

[SRC]|| ((security.hasEntityPermission("PROJECTMGR", "_ROLE_A..ltAssign)) {

[MSG]The line exceeds 150 characters. The line is 169 characters.

ConsecutiveBlankLines320

[MSG]File ListCurrentProjects.groovy has consecutive blank lines

UnnecessaryGString327

[SRC]EntityCondition.makeCondition ("workEffortTypeId", Entit.. "PROJECT"),

[MSG]The String 'workEffortTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString327

[SRC]EntityCondition.makeCondition ("workEffortTypeId", Entit.. "PROJECT"),

[MSG]The String 'PROJECT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]EntityCondition.makeCondition ("currentStatusId", Entity..PRJ_CLOSED")

[MSG]The String 'currentStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]EntityCondition.makeCondition ("currentStatusId", Entity..PRJ_CLOSED")

[MSG]The String 'PRJ_CLOSED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]allProjects = select("workEffortId").from("WorkEffort")....queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]allProjects = select("workEffortId").from("WorkEffort")....queryList()

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]allProjects = select("workEffortId").from("WorkEffort")....queryList()

[MSG]The String 'workEffortName' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon334

[SRC]result = runService('getProject', ["userLogin" : paramet..rkEffortId])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.projectmgr.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon334

[SRC]result = runService('getProject', ["userLogin" : paramet..rkEffortId])

[MSG]The colon for the literal Map entry for key [projectId] within class org.apache.ofbiz.projectmgr.None is not preceded by a match for regular expression [\S]

UnnecessaryGString334

[SRC]result = runService('getProject', ["userLogin" : paramet..rkEffortId])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]result = runService('getProject', ["userLogin" : paramet..rkEffortId])

[MSG]The String 'projectId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]resultAssign = from("WorkEffortPartyAssignment").where("...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]resultAssign = from("WorkEffortPartyAssignment").where("...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]resultAssign = from("WorkEffortPartyAssignment").where("...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]if (security.hasEntityPermission("PROJECTMGR", "_ADMIN", session)

[MSG]The String 'PROJECTMGR' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]if (security.hasEntityPermission("PROJECTMGR", "_ADMIN", session)

[MSG]The String '_ADMIN' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]|| ((security.hasEntityPermission("PROJECTMGR", "_ROLE_A..ltAssign)) {

[MSG]The String 'PROJECTMGR' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]|| ((security.hasEntityPermission("PROJECTMGR", "_ROLE_A..ltAssign)) {

[MSG]The String '_ROLE_ADMIN' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]|| ((security.hasEntityPermission("PROJECTMGR", "_ROLE_A..ltAssign)) {

[MSG]The String 'PROJECTMGR' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]|| ((security.hasEntityPermission("PROJECTMGR", "_ROLE_A..ltAssign)) {

[MSG]The String '_ROLE_VIEW' can be wrapped in single quotes instead of double quotes

➥ ListResourceBillingHours.groovy

Rule NamePriorityLine #Source Line / Message
LineLength221

[SRC]allProjects = select("workEffortId").from("WorkEffortAnd...queryList()

[MSG]The line exceeds 150 characters. The line is 187 characters.

UnnecessaryGString321

[SRC]allProjects = select("workEffortId").from("WorkEffortAnd...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString321

[SRC]allProjects = select("workEffortId").from("WorkEffortAnd...queryList()

[MSG]The String 'WorkEffortAndPartyAssign' can be wrapped in single quotes instead of double quotes

UnnecessaryGString321

[SRC]allProjects = select("workEffortId").from("WorkEffortAnd...queryList()

[MSG]The String 'workEffortTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString321

[SRC]allProjects = select("workEffortId").from("WorkEffortAnd...queryList()

[MSG]The String 'PROJECT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString321

[SRC]allProjects = select("workEffortId").from("WorkEffortAnd...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString321

[SRC]allProjects = select("workEffortId").from("WorkEffortAnd...queryList()

[MSG]The String 'workEffortName' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon325

[SRC]result = runService('getProject', ["userLogin" : paramet..rs.partyId])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.projectmgr.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon325

[SRC]result = runService('getProject', ["userLogin" : paramet..rs.partyId])

[MSG]The colon for the literal Map entry for key [projectId] within class org.apache.ofbiz.projectmgr.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon325

[SRC]result = runService('getProject', ["userLogin" : paramet..rs.partyId])

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.projectmgr.None is not preceded by a match for regular expression [\S]

UnnecessaryGString325

[SRC]result = runService('getProject', ["userLogin" : paramet..rs.partyId])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString325

[SRC]result = runService('getProject', ["userLogin" : paramet..rs.partyId])

[MSG]The String 'projectId' can be wrapped in single quotes instead of double quotes

➥ ProjectBilling.groovy

Rule NamePriorityLine #Source Line / Message
AssignmentInConditional242

[SRC]while (entryItem = entryIterator.next()) {

[MSG]Assignment used as conditional value, which always results in true. Use the == operator instead

ExplicitCallToEqualsMethod244

[SRC]if ("INVOICE_IN_PROCESS".equals(invoice.getString("statusId"))) {

[MSG]Violation in class org.apache.ofbiz.projectmgr.None. Explicit call to INVOICE_IN_PROCESS.equals(invoice.getString(statusId)) method can be rewritten as (INVOICE_IN_PROCESS == (invoice.getString(statusId)))

ConsecutiveBlankLines321

[MSG]File ProjectBilling.groovy has consecutive blank lines

UnnecessaryGString330

[SRC]EntityCondition.makeCondition("projectId", EntityOperato.. projectId),

[MSG]The String 'projectId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString331

[SRC]EntityCondition.makeCondition("invoiceId", EntityOperato..QUAL, null),

[MSG]The String 'invoiceId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]orderBy = ["-fromDate"]

[MSG]The String '-fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]entryIterator = from("ProjectPhaseTaskAndTimeEntryTimeSheet")

[MSG]The String 'ProjectPhaseTaskAndTimeEntryTimeSheet' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]EntityCondition.makeCondition("projectId", EntityOperato.. projectId),

[MSG]The String 'projectId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]EntityCondition.makeCondition("invoiceId", EntityOperato..QUAL, null),

[MSG]The String 'invoiceId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC].orderBy("-fromDate")

[MSG]The String '-fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]invoice = entryItem.getRelatedOne("Invoice", false)

[MSG]The String 'Invoice' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]if ("INVOICE_IN_PROCESS".equals(invoice.getString("statusId"))) {

[MSG]The String 'INVOICE_IN_PROCESS' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]if ("INVOICE_IN_PROCESS".equals(invoice.getString("statusId"))) {

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

➥ ProjectIsBillable.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod226

[SRC]if ("INTERNAL_ORGANIZATIO".equals(member.roleTypeId)) {

[MSG]Violation in class org.apache.ofbiz.projectmgr.None. Explicit call to INTERNAL_ORGANIZATIO.equals(member.roleTypeId) method can be rewritten as (INTERNAL_ORGANIZATIO == (member.roleTypeId))

ExplicitCallToEqualsMethod229

[SRC]if ("CLIENT_BILLING".equals(member.roleTypeId)) {

[MSG]Violation in class org.apache.ofbiz.projectmgr.None. Explicit call to CLIENT_BILLING.equals(member.roleTypeId) method can be rewritten as (CLIENT_BILLING == (member.roleTypeId))

ExplicitCallToEqualsMethod232

[SRC]if (fromPartyId && toPartyId && fromPartyId.equals(toPartyId)) {

[MSG]Violation in class org.apache.ofbiz.projectmgr.None. Explicit call to fromPartyId.equals(toPartyId) method can be rewritten as (fromPartyId == (toPartyId))

UnnecessaryGString321

[SRC]projectMembers = from("WorkEffortPartyAssignment").where...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString321

[SRC]projectMembers = from("WorkEffortPartyAssignment").where...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

SpaceAfterOpeningBrace325

[SRC]projectMembers.each {member ->

[MSG]The opening brace for the closure in class org.apache.ofbiz.projectmgr.None is not followed by a space or whitespace

UnnecessaryGString326

[SRC]if ("INTERNAL_ORGANIZATIO".equals(member.roleTypeId)) {

[MSG]The String 'INTERNAL_ORGANIZATIO' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]if ("CLIENT_BILLING".equals(member.roleTypeId)) {

[MSG]The String 'CLIENT_BILLING' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace334

[SRC]} else if (!toPartyId || !fromPartyId){

[MSG]The opening brace for the block in class org.apache.ofbiz.projectmgr.None is not preceded by a space or whitespace

TrailingWhitespace336

[SRC]} else {

[MSG]Line ends with whitespace characters

Package: org.apache.ofbiz.scrum

➥ AddProductBacklogItem.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod232

[SRC]}else if("Any".equals(parameters.statusId)){

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to Any.equals(parameters.statusId) method can be rewritten as (Any == (parameters.statusId))

LineLength237

[SRC]def performFindResults = runService('performFind', ["ent..quenceNum"])

[MSG]The line exceeds 150 characters. The line is 157 characters.

ExplicitCallToEqualsMethod280

[SRC]if ("N".equals(parameters.sequence)) { // re-order category list item

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to N.equals(parameters.sequence) method can be rewritten as (N == (parameters.sequence))

ExplicitCallToEqualsMethod284

[SRC]if("".equals(parameters.statusId)){

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to .equals(parameters.statusId) method can be rewritten as ( == (parameters.statusId))

LineLength2109

[SRC]unplannedList = select("custRequestId", "custSequenceNum...queryList()

[MSG]The line exceeds 150 characters. The line is 258 characters.

ExplicitCallToEqualsMethod2137

[SRC]if ("N".equals(parameters.UnplannedSequence)) { // re-or..ry list item

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to N.equals(parameters.UnplannedSequence) method can be rewritten as (N == (parameters.UnplannedSequence))

NoDef327

[SRC]def inputFields = [:]

[MSG]def for declaration should not be used

VariableTypeRequired327

[SRC]def inputFields = [:]

[MSG]The type is not specified for variable "inputFields"

NoDef328

[SRC]def custRequestAndItems = []

[MSG]def for declaration should not be used

VariableTypeRequired328

[SRC]def custRequestAndItems = []

[MSG]The type is not specified for variable "custRequestAndItems"

SpaceAfterClosingBrace330

[SRC]if(parameters.statusId == null){

[MSG]The closing brace for the block in class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAfterIf330

[SRC]if(parameters.statusId == null){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace330

[SRC]if(parameters.statusId == null){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString331

[SRC]parameters.statusId = ""

[MSG]The String '' can be wrapped in single quotes instead of double quotes

SpaceAfterIf332

[SRC]}else if("Any".equals(parameters.statusId)){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace332

[SRC]}else if("Any".equals(parameters.statusId)){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString332

[SRC]}else if("Any".equals(parameters.statusId)){

[MSG]The String 'Any' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]parameters.statusId = ""

[MSG]The String '' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]inputFields.custRequestTypeId = "RF_PROD_BACKLOG"

[MSG]The String 'RF_PROD_BACKLOG' can be wrapped in single quotes instead of double quotes

NoDef337

[SRC]def performFindResults = runService('performFind', ["ent..quenceNum"])

[MSG]def for declaration should not be used

VariableTypeRequired337

[SRC]def performFindResults = runService('performFind', ["ent..quenceNum"])

[MSG]The type is not specified for variable "performFindResults"

UnnecessaryGString337

[SRC]def performFindResults = runService('performFind', ["ent..quenceNum"])

[MSG]The String 'entityName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]def performFindResults = runService('performFind', ["ent..quenceNum"])

[MSG]The String 'CustRequestAndCustRequestItem' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]def performFindResults = runService('performFind', ["ent..quenceNum"])

[MSG]The String 'inputFields' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]def performFindResults = runService('performFind', ["ent..quenceNum"])

[MSG]The String 'orderBy' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]def performFindResults = runService('performFind', ["ent..quenceNum"])

[MSG]The String 'custSequenceNum' can be wrapped in single quotes instead of double quotes

UnnecessaryGString341

[SRC]logError(e, "Failure in " + module)

[MSG]The String 'Failure in ' can be wrapped in single quotes instead of double quotes

Indentation347

[SRC]logError(e)

[MSG]The statement on line 47 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 17

NoDef353

[SRC]def countSequence = 1

[MSG]def for declaration should not be used

VariableTypeRequired353

[SRC]def countSequence = 1

[MSG]The type is not specified for variable "countSequence"

NoDef354

[SRC]def custRequestAndCustRequestItems = []

[MSG]def for declaration should not be used

VariableTypeRequired354

[SRC]def custRequestAndCustRequestItems = []

[MSG]The type is not specified for variable "custRequestAndCustRequestItems"

UnnecessaryParenthesesForMethodCallWithClosure355

[SRC]custRequestAndItems.each() { custRequestAndItem ->

[MSG]Violation in class org.apache.ofbiz.scrum.None. Parentheses in the 'each' method call are unnecessary and can be removed.

NoDef356

[SRC]def tempCustRequestAndItem = [:]

[MSG]def for declaration should not be used

VariableTypeRequired356

[SRC]def tempCustRequestAndItem = [:]

[MSG]The type is not specified for variable "tempCustRequestAndItem"

UnnecessaryGString361

[SRC]custWorkEffortList = from("CustRequestWorkEffort").where...queryList()

[MSG]The String 'CustRequestWorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]custWorkEffortList = from("CustRequestWorkEffort").where...queryList()

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryParenthesesForMethodCallWithClosure364

[SRC]custWorkEffortList.each() { custWorkEffortMap ->

[MSG]Violation in class org.apache.ofbiz.scrum.None. Parentheses in the 'each' method call are unnecessary and can be removed.

SpaceAfterComma365

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The map entry partyId:null within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundMapEntryColon365

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The colon for the literal Map entry for key [taskId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon365

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon365

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString365

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The String 'taskId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

SpaceAfterIf368

[SRC]if(actualHours) {

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

UnnecessaryGString380

[SRC]if ("N".equals(parameters.sequence)) { // re-order category list item

[MSG]The String 'N' can be wrapped in single quotes instead of double quotes

UnnecessaryGString381

[SRC]custRequestAndCustRequestItems = UtilMisc.sortMaps(custR..RequestId"])

[MSG]The String 'parentCustRequestId' can be wrapped in single quotes instead of double quotes

SpaceAfterIf384

[SRC]if("".equals(parameters.statusId)){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace384

[SRC]if("".equals(parameters.statusId)){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString384

[SRC]if("".equals(parameters.statusId)){

[MSG]The String '' can be wrapped in single quotes instead of double quotes

UnnecessaryGString385

[SRC]parameters.statusId = "Any"

[MSG]The String 'Any' can be wrapped in single quotes instead of double quotes

UnnecessaryGString397

[SRC]conditionList.add(EntityCondition.makeCondition("custReq..N_BACKLOG"))

[MSG]The String 'custRequestTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString397

[SRC]conditionList.add(EntityCondition.makeCondition("custReq..N_BACKLOG"))

[MSG]The String 'RF_UNPLAN_BACKLOG' can be wrapped in single quotes instead of double quotes

UnnecessaryGString398

[SRC]conditionList.add(EntityCondition.makeCondition("product...productId))

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3100

[SRC]orConditionList.add(EntityCondition.makeCondition("statu.._ACCEPTED"))

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3100

[SRC]orConditionList.add(EntityCondition.makeCondition("statu.._ACCEPTED"))

[MSG]The String 'CRQ_ACCEPTED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3101

[SRC]orConditionList.add(EntityCondition.makeCondition("statu.._REOPENED"))

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3101

[SRC]orConditionList.add(EntityCondition.makeCondition("statu.._REOPENED"))

[MSG]The String 'CRQ_REOPENED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3109

[SRC]unplannedList = select("custRequestId", "custSequenceNum...queryList()

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3109

[SRC]unplannedList = select("custRequestId", "custSequenceNum...queryList()

[MSG]The String 'custSequenceNum' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3109

[SRC]unplannedList = select("custRequestId", "custSequenceNum...queryList()

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3109

[SRC]unplannedList = select("custRequestId", "custSequenceNum...queryList()

[MSG]The String 'description' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3109

[SRC]unplannedList = select("custRequestId", "custSequenceNum...queryList()

[MSG]The String 'custEstimatedMilliSeconds' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3109

[SRC]unplannedList = select("custRequestId", "custSequenceNum...queryList()

[MSG]The String 'custRequestName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3109

[SRC]unplannedList = select("custRequestId", "custSequenceNum...queryList()

[MSG]The String 'parentCustRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3109

[SRC]unplannedList = select("custRequestId", "custSequenceNum...queryList()

[MSG]The String 'CustRequestAndCustRequestItem' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3109

[SRC]unplannedList = select("custRequestId", "custSequenceNum...queryList()

[MSG]The String 'custSequenceNum' can be wrapped in single quotes instead of double quotes

NoDef3111

[SRC]def countSequenceUnplanned = 1

[MSG]def for declaration should not be used

VariableTypeRequired3111

[SRC]def countSequenceUnplanned = 1

[MSG]The type is not specified for variable "countSequenceUnplanned"

NoDef3112

[SRC]def unplanBacklogItems = []

[MSG]def for declaration should not be used

VariableTypeRequired3112

[SRC]def unplanBacklogItems = []

[MSG]The type is not specified for variable "unplanBacklogItems"

UnnecessaryParenthesesForMethodCallWithClosure3113

[SRC]unplannedList.each() { unplannedItem ->

[MSG]Violation in class org.apache.ofbiz.scrum.None. Parentheses in the 'each' method call are unnecessary and can be removed.

NoDef3114

[SRC]def tempUnplanned = [:]

[MSG]def for declaration should not be used

VariableTypeRequired3114

[SRC]def tempUnplanned = [:]

[MSG]The type is not specified for variable "tempUnplanned"

UnnecessaryGString3119

[SRC]unplanCustWorkEffortList = from("CustRequestWorkEffort")...queryList()

[MSG]The String 'CustRequestWorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3119

[SRC]unplanCustWorkEffortList = from("CustRequestWorkEffort")...queryList()

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryParenthesesForMethodCallWithClosure3122

[SRC]unplanCustWorkEffortList.each() { custWorkEffortMap ->

[MSG]Violation in class org.apache.ofbiz.scrum.None. Parentheses in the 'each' method call are unnecessary and can be removed.

SpaceAfterComma3123

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The map entry partyId:null within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundMapEntryColon3123

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The colon for the literal Map entry for key [taskId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3123

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3123

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3123

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The String 'taskId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3123

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3123

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

SpaceAfterIf3126

[SRC]if(actualHours) {

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

UnnecessaryGString3137

[SRC]if ("N".equals(parameters.UnplannedSequence)) { // re-or..ry list item

[MSG]The String 'N' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3138

[SRC]unplanBacklogItems = UtilMisc.sortMaps(unplanBacklogItem..RequestId"])

[MSG]The String 'parentCustRequestId' can be wrapped in single quotes instead of double quotes

➥ AddResourceTaskParty.groovy

Rule NamePriorityLine #Source Line / Message
LineLength224

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The line exceeds 150 characters. The line is 166 characters.

ExplicitCallToEqualsMethod247

[SRC]if ("RF_SCRUM_MEETINGS".equals(custRequestTypeId) && "CR..StatusId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to RF_SCRUM_MEETINGS.equals(custRequestTypeId) method can be rewritten as (RF_SCRUM_MEETINGS == (custRequestTypeId))

ExplicitCallToEqualsMethod247

[SRC]if ("RF_SCRUM_MEETINGS".equals(custRequestTypeId) && "CR..StatusId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to CRQ_REVIEWED.equals(backlogStatusId) method can be rewritten as (CRQ_REVIEWED == (backlogStatusId))

SpaceAfterComma324

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The parameter taskCurrentStatusId in the call to method where within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString324

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The String 'ProjectSprintBacklogAndTask' can be wrapped in single quotes instead of double quotes

UnnecessaryGString324

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The String 'sprintTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString324

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The String 'SCRUM_SPRINT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString324

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The String 'taskCurrentStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString324

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The String 'STS_CREATED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString324

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The String 'taskId DESC' can be wrapped in single quotes instead of double quotes

Indentation326

[SRC]userLoginId = userLogin.partyId

[MSG]The statement on line 26 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [5, 9, 13] or one of [23, 27, 31] columns, but was 1

UnnecessaryGString328

[SRC]partyAssignmentProjectList = from("WorkEffortPartyAssign...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]partyAssignmentProjectList = from("WorkEffortPartyAssign...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]partyAssignmentProjectList = from("WorkEffortPartyAssign...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]partyAssignmentSprintList = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]partyAssignmentSprintList = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]partyAssignmentSprintList = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]partyAssignmentTaskList = from("WorkEffortPartyAssignmen...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]partyAssignmentTaskList = from("WorkEffortPartyAssignmen...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

InvertedIfElse341

[SRC]if (!partyAssignmentTaskMap) {

[MSG]Testing the negative condition first can make an if statement confusing

UnnecessaryGString347

[SRC]if ("RF_SCRUM_MEETINGS".equals(custRequestTypeId) && "CR..StatusId)) {

[MSG]The String 'RF_SCRUM_MEETINGS' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]if ("RF_SCRUM_MEETINGS".equals(custRequestTypeId) && "CR..StatusId)) {

[MSG]The String 'CRQ_REVIEWED' can be wrapped in single quotes instead of double quotes

➥ BacklogNotifications.groovy

Rule NamePriorityLine #Source Line / Message
UnusedVariable222

[SRC]def module = "BacklogNotifications.groovy"

[MSG]The variable [module] in class org.apache.ofbiz.scrum.None is not used

LineLength233

[SRC]backlogList = select("productId", "workEffortId", "custR...queryList()

[MSG]The line exceeds 150 characters. The line is 175 characters.

ExplicitCallToEqualsMethod253

[SRC]if ("CRQ_ACCEPTED".equals(custRequest.statusId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to CRQ_ACCEPTED.equals(custRequest.statusId) method can be rewritten as (CRQ_ACCEPTED == (custRequest.statusId))

ExplicitCallToEqualsMethod255

[SRC]if (custStatusList.size() > 2 && "CRQ_REVIEWED".equals(c..statusId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to CRQ_REVIEWED.equals(custStatusList[1].statusId) method can be rewritten as (CRQ_REVIEWED == (custStatusList[1].statusId))

ConsecutiveBlankLines320

[MSG]File BacklogNotifications.groovy has consecutive blank lines

NoDef322

[SRC]def module = "BacklogNotifications.groovy"

[MSG]def for declaration should not be used

VariableTypeRequired322

[SRC]def module = "BacklogNotifications.groovy"

[MSG]The type is not specified for variable "module"

UnnecessaryGString322

[SRC]def module = "BacklogNotifications.groovy"

[MSG]The String 'BacklogNotifications.groovy' can be wrapped in single quotes instead of double quotes

UnnecessaryGString324

[SRC]custRequest = from("CustRequest").where("custRequestId",..).queryOne()

[MSG]The String 'CustRequest' can be wrapped in single quotes instead of double quotes

UnnecessaryGString324

[SRC]custRequest = from("CustRequest").where("custRequestId",..).queryOne()

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString325

[SRC]person = from("PartyNameView").where("partyId", partyIdTo).queryOne()

[MSG]The String 'PartyNameView' can be wrapped in single quotes instead of double quotes

UnnecessaryGString325

[SRC]person = from("PartyNameView").where("partyId", partyIdTo).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]backlogList = select("productId", "workEffortId", "custR...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]backlogList = select("productId", "workEffortId", "custR...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]backlogList = select("productId", "workEffortId", "custR...queryList()

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]backlogList = select("productId", "workEffortId", "custR...queryList()

[MSG]The String 'ProductBacklog' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]backlogList = select("productId", "workEffortId", "custR...queryList()

[MSG]The String 'workEffortTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]backlogList = select("productId", "workEffortId", "custR...queryList()

[MSG]The String 'SCRUM_SPRINT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]backlogList = select("productId", "workEffortId", "custR...queryList()

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]product = from("Product").where("productId", backlogList..).queryOne()

[MSG]The String 'Product' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]product = from("Product").where("productId", backlogList..).queryOne()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]sprint = from("WorkEffort").where("workEffortId", backlo..).queryOne()

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]sprint = from("WorkEffort").where("workEffortId", backlo..).queryOne()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC]backlogList = select("productId", "workEffortId", "custR...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC]backlogList = select("productId", "workEffortId", "custR...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC]backlogList = select("productId", "workEffortId", "custR...queryList()

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC]backlogList = select("productId", "workEffortId", "custR...queryList()

[MSG]The String 'ProductBacklog' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC]backlogList = select("productId", "workEffortId", "custR...queryList()

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString345

[SRC]product = from("Product").where("productId", backlogList..).queryOne()

[MSG]The String 'Product' can be wrapped in single quotes instead of double quotes

UnnecessaryGString345

[SRC]product = from("Product").where("productId", backlogList..).queryOne()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString353

[SRC]if ("CRQ_ACCEPTED".equals(custRequest.statusId)) {

[MSG]The String 'CRQ_ACCEPTED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString354

[SRC]custStatusList = custRequest.getRelated("CustRequestStat..Id"], false)

[MSG]The String 'CustRequestStatus' can be wrapped in single quotes instead of double quotes

UnnecessaryGString354

[SRC]custStatusList = custRequest.getRelated("CustRequestStat..Id"], false)

[MSG]The String '-custRequestStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]if (custStatusList.size() > 2 && "CRQ_REVIEWED".equals(c..statusId)) {

[MSG]The String 'CRQ_REVIEWED' can be wrapped in single quotes instead of double quotes

➥ EditDailyHourReport.groovy

Rule NamePriorityLine #Source Line / Message
IfStatementBraces263

[SRC]if (!timesheet) return

[MSG]The if statement lacks braces

IfStatementBraces2105

[SRC]if (estimatedMilliSeconds > 0)

[MSG]The if statement lacks braces

LineLength2111

[SRC]lastTimeEntryOfTasks = from("TimeEntry").where("workEffo...queryList()

[MSG]The line exceeds 150 characters. The line is 155 characters.

IfStatementBraces2112

[SRC]if (lastTimeEntryOfTasks.size() != 0) lastTimeEntry = la..ryOfTasks[0]

[MSG]The if statement lacks braces

LineLength2126

[SRC]workEffortPartyAssigns = EntityUtil.filterByDate(entryWo..ull, false))

[MSG]The line exceeds 150 characters. The line is 153 characters.

ExplicitCallToEqualsMethod2131

[SRC]if ("SCAS_COMPLETED".equals(workEffortPartyAssign.statusId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to SCAS_COMPLETED.equals(workEffortPartyAssign.statusId) method can be rewritten as (SCAS_COMPLETED == (workEffortPartyAssign.statusId))

ExplicitCallToEqualsMethod2136

[SRC]if ("STS_COMPLETED".equals(entryWorkEffort.currentStatusId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to STS_COMPLETED.equals(entryWorkEffort.currentStatusId) method can be rewritten as (STS_COMPLETED == (entryWorkEffort.currentStatusId))

IfStatementBraces2156

[SRC]if (aHours > 0.00)

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2177

[SRC](!lastTimeEntry.workEffortId.equals(timeEntry.workEffortId) ||

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to lastTimeEntry.workEffortId.equals(timeEntry.workEffortId) method can be rewritten as (lastTimeEntry.workEffortId == (timeEntry.workEffortId))

ExplicitCallToEqualsMethod2178

[SRC]!lastTimeEntry.rateTypeId.equals(timeEntry.rateTypeId))) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to lastTimeEntry.rateTypeId.equals(timeEntry.rateTypeId) method can be rewritten as (lastTimeEntry.rateTypeId == (timeEntry.rateTypeId))

IfStatementBraces2185

[SRC]if ("d0".equals(dayNumber)) day0Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2185

[SRC]if ("d0".equals(dayNumber)) day0Total += hours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d0.equals(dayNumber) method can be rewritten as (d0 == (dayNumber))

IfStatementBraces2186

[SRC]if ("d1".equals(dayNumber)) day1Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2186

[SRC]if ("d1".equals(dayNumber)) day1Total += hours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d1.equals(dayNumber) method can be rewritten as (d1 == (dayNumber))

IfStatementBraces2187

[SRC]if ("d2".equals(dayNumber)) day2Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2187

[SRC]if ("d2".equals(dayNumber)) day2Total += hours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d2.equals(dayNumber) method can be rewritten as (d2 == (dayNumber))

IfStatementBraces2188

[SRC]if ("d3".equals(dayNumber)) day3Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2188

[SRC]if ("d3".equals(dayNumber)) day3Total += hours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d3.equals(dayNumber) method can be rewritten as (d3 == (dayNumber))

IfStatementBraces2189

[SRC]if ("d4".equals(dayNumber)) day4Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2189

[SRC]if ("d4".equals(dayNumber)) day4Total += hours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d4.equals(dayNumber) method can be rewritten as (d4 == (dayNumber))

IfStatementBraces2190

[SRC]if ("d5".equals(dayNumber)) day5Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2190

[SRC]if ("d5".equals(dayNumber)) day5Total += hours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d5.equals(dayNumber) method can be rewritten as (d5 == (dayNumber))

IfStatementBraces2191

[SRC]if ("d6".equals(dayNumber)) day6Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2191

[SRC]if ("d6".equals(dayNumber)) day6Total += hours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d6.equals(dayNumber) method can be rewritten as (d6 == (dayNumber))

IfStatementBraces2198

[SRC]if ("pd0".equals(dayNumber)) pDay0Total += planHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2198

[SRC]if ("pd0".equals(dayNumber)) pDay0Total += planHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to pd0.equals(dayNumber) method can be rewritten as (pd0 == (dayNumber))

IfStatementBraces2199

[SRC]if ("pd1".equals(dayNumber)) pDay1Total += planHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2199

[SRC]if ("pd1".equals(dayNumber)) pDay1Total += planHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to pd1.equals(dayNumber) method can be rewritten as (pd1 == (dayNumber))

IfStatementBraces2200

[SRC]if ("pd2".equals(dayNumber)) pDay2Total += planHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2200

[SRC]if ("pd2".equals(dayNumber)) pDay2Total += planHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to pd2.equals(dayNumber) method can be rewritten as (pd2 == (dayNumber))

IfStatementBraces2201

[SRC]if ("pd3".equals(dayNumber)) pDay3Total += planHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2201

[SRC]if ("pd3".equals(dayNumber)) pDay3Total += planHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to pd3.equals(dayNumber) method can be rewritten as (pd3 == (dayNumber))

IfStatementBraces2202

[SRC]if ("pd4".equals(dayNumber)) pDay4Total += planHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2202

[SRC]if ("pd4".equals(dayNumber)) pDay4Total += planHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to pd4.equals(dayNumber) method can be rewritten as (pd4 == (dayNumber))

IfStatementBraces2203

[SRC]if ("pd5".equals(dayNumber)) pDay5Total += planHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2203

[SRC]if ("pd5".equals(dayNumber)) pDay5Total += planHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to pd5.equals(dayNumber) method can be rewritten as (pd5 == (dayNumber))

IfStatementBraces2204

[SRC]if ("pd6".equals(dayNumber)) pDay6Total += planHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2204

[SRC]if ("pd6".equals(dayNumber)) pDay6Total += planHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to pd6.equals(dayNumber) method can be rewritten as (pd6 == (dayNumber))

LineLength2215

[SRC]["userLogin": parameters.userLogin, "partyId": lastEmplL..y.fromDate])

[MSG]The line exceeds 150 characters. The line is 179 characters.

AssignmentInConditional2247

[SRC]while ((emplLeaveMap = emplLeave.next())) {

[MSG]Assignment used as conditional value, which always results in true. Use the == operator instead

ExplicitCallToEqualsMethod2255

[SRC]!lastEmplLeaveEntry.leaveTypeId.equals(emplLeaveEntry.leaveTypeId) ||

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to lastEmplLeaveEntry.leaveTypeId.equals(emplLeaveEntry.leaveTypeId) method can be rewritten as (lastEmplLeaveEntry.leaveTypeId == (emplLeaveEntry.leaveTypeId))

ExplicitCallToEqualsMethod2256

[SRC]!lastEmplLeaveEntry.partyId.equals(emplLeaveEntry.partyId))) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to lastEmplLeaveEntry.partyId.equals(emplLeaveEntry.partyId) method can be rewritten as (lastEmplLeaveEntry.partyId == (emplLeaveEntry.partyId))

LineLength2260

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The line exceeds 150 characters. The line is 159 characters.

LineLength2265

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The line exceeds 150 characters. The line is 163 characters.

IfStatementBraces2268

[SRC]if ("d0".equals(leaveDayNumber)) day0Total += leaveHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2268

[SRC]if ("d0".equals(leaveDayNumber)) day0Total += leaveHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d0.equals(leaveDayNumber) method can be rewritten as (d0 == (leaveDayNumber))

IfStatementBraces2269

[SRC]if ("d1".equals(leaveDayNumber)) day1Total += leaveHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2269

[SRC]if ("d1".equals(leaveDayNumber)) day1Total += leaveHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d1.equals(leaveDayNumber) method can be rewritten as (d1 == (leaveDayNumber))

IfStatementBraces2270

[SRC]if ("d2".equals(leaveDayNumber)) day2Total += leaveHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2270

[SRC]if ("d2".equals(leaveDayNumber)) day2Total += leaveHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d2.equals(leaveDayNumber) method can be rewritten as (d2 == (leaveDayNumber))

IfStatementBraces2271

[SRC]if ("d3".equals(leaveDayNumber)) day3Total += leaveHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2271

[SRC]if ("d3".equals(leaveDayNumber)) day3Total += leaveHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d3.equals(leaveDayNumber) method can be rewritten as (d3 == (leaveDayNumber))

IfStatementBraces2272

[SRC]if ("d4".equals(leaveDayNumber)) day4Total += leaveHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2272

[SRC]if ("d4".equals(leaveDayNumber)) day4Total += leaveHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d4.equals(leaveDayNumber) method can be rewritten as (d4 == (leaveDayNumber))

IfStatementBraces2273

[SRC]if ("d5".equals(leaveDayNumber)) day5Total += leaveHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2273

[SRC]if ("d5".equals(leaveDayNumber)) day5Total += leaveHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d5.equals(leaveDayNumber) method can be rewritten as (d5 == (leaveDayNumber))

IfStatementBraces2274

[SRC]if ("d6".equals(leaveDayNumber)) day6Total += leaveHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2274

[SRC]if ("d6".equals(leaveDayNumber)) day6Total += leaveHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d6.equals(leaveDayNumber) method can be rewritten as (d6 == (leaveDayNumber))

LineLength2280

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The line exceeds 150 characters. The line is 163 characters.

IfStatementBraces2283

[SRC]if ("pd0".equals(leavePlanDay)) pDay0Total += leavePlanHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2283

[SRC]if ("pd0".equals(leavePlanDay)) pDay0Total += leavePlanHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to pd0.equals(leavePlanDay) method can be rewritten as (pd0 == (leavePlanDay))

IfStatementBraces2284

[SRC]if ("pd1".equals(leavePlanDay)) pDay1Total += leavePlanHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2284

[SRC]if ("pd1".equals(leavePlanDay)) pDay1Total += leavePlanHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to pd1.equals(leavePlanDay) method can be rewritten as (pd1 == (leavePlanDay))

IfStatementBraces2285

[SRC]if ("pd2".equals(leavePlanDay)) pDay2Total += leavePlanHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2285

[SRC]if ("pd2".equals(leavePlanDay)) pDay2Total += leavePlanHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to pd2.equals(leavePlanDay) method can be rewritten as (pd2 == (leavePlanDay))

IfStatementBraces2286

[SRC]if ("pd3".equals(leavePlanDay)) pDay3Total += leavePlanHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2286

[SRC]if ("pd3".equals(leavePlanDay)) pDay3Total += leavePlanHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to pd3.equals(leavePlanDay) method can be rewritten as (pd3 == (leavePlanDay))

IfStatementBraces2287

[SRC]if ("pd4".equals(leavePlanDay)) pDay4Total += leavePlanHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2287

[SRC]if ("pd4".equals(leavePlanDay)) pDay4Total += leavePlanHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to pd4.equals(leavePlanDay) method can be rewritten as (pd4 == (leavePlanDay))

IfStatementBraces2288

[SRC]if ("pd5".equals(leavePlanDay)) pDay5Total += leavePlanHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2288

[SRC]if ("pd5".equals(leavePlanDay)) pDay5Total += leavePlanHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to pd5.equals(leavePlanDay) method can be rewritten as (pd5 == (leavePlanDay))

IfStatementBraces2289

[SRC]if ("pd6".equals(leavePlanDay)) pDay6Total += leavePlanHours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2289

[SRC]if ("pd6".equals(leavePlanDay)) pDay6Total += leavePlanHours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to pd6.equals(leavePlanDay) method can be rewritten as (pd6 == (leavePlanDay))

ExplicitCallToEqualsMethod2306

[SRC]if (!"TIMESHEET_COMPLETED".equals(timesheet.statusId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to TIMESHEET_COMPLETED.equals(timesheet.statusId) method can be rewritten as (TIMESHEET_COMPLETED == (timesheet.statusId))

ExplicitLinkedListInstantiation2337

[SRC]timesheets = new LinkedList()

[MSG]LinkedList objects are better instantiated using the form "[] as Queue"

AssignmentInConditional2348

[SRC]while ((emplLeaveMap = emplLeaveList.next())) {

[MSG]Assignment used as conditional value, which always results in true. Use the == operator instead

LineLength2351

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The line exceeds 150 characters. The line is 163 characters.

LineLength2378

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The line exceeds 150 characters. The line is 199 characters.

ExplicitCallToEqualsMethod2396

[SRC]if ("RF_SCRUM_MEETINGS".equals(custRequestTypeId) && "CR..StatusId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to RF_SCRUM_MEETINGS.equals(custRequestTypeId) method can be rewritten as (RF_SCRUM_MEETINGS == (custRequestTypeId))

ExplicitCallToEqualsMethod2396

[SRC]if ("RF_SCRUM_MEETINGS".equals(custRequestTypeId) && "CR..StatusId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to CRQ_REVIEWED.equals(backlogStatusId) method can be rewritten as (CRQ_REVIEWED == (backlogStatusId))

LineLength2409

[SRC]custRequestList = from("CustRequest").where("custRequest...queryList()

[MSG]The line exceeds 150 characters. The line is 160 characters.

ExplicitCallToEqualsMethod2418

[SRC]if (productId.equals(productOut)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to productId.equals(productOut) method can be rewritten as (productId == (productOut))

LineLength2421

[SRC]partyAssignmentTaskList = from("WorkEffortPartyAssignmen...queryList()

[MSG]The line exceeds 150 characters. The line is 156 characters.

NoWildcardImports321

[SRC]import java.util.*

[MSG]Wildcard (star) import

UnnecessaryGroovyImport321

[SRC]import java.util.*

NoWildcardImports322

[SRC]import java.lang.*

[MSG]Wildcard (star) import

UnnecessaryGroovyImport322

[SRC]import java.lang.*

UnnecessaryGString333

[SRC]uiLabelMap = UtilProperties.getResourceBundleMap("scrumU..ls", locale)

[MSG]The String 'scrumUiLabels' can be wrapped in single quotes instead of double quotes

CouldBeElvis335

[SRC]if (!partyId) {

[MSG]Code could use elvis operator: partyId = partyId ?: parameters.userLogin.partyId

UnnecessaryGString343

[SRC]timesheet = from("Timesheet").where("timesheetId", times..).queryOne()

[MSG]The String 'Timesheet' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]timesheet = from("Timesheet").where("timesheetId", times..).queryOne()

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

SpaceAfterComma347

[SRC]midweek = UtilDateTime.addDaysToTimestamp(UtilDateTime.g..estamp()),3)

[MSG]The parameter 3 in the call to method addDaysToTimestamp within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString349

[SRC]EntityCondition.makeCondition("fromDate", EntityComparis..N, midweek),

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]EntityCondition.makeCondition("thruDate", EntityComparis..N, midweek),

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString351

[SRC]EntityCondition.makeCondition("partyId", EntityCompariso..LS, partyId)

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString353

[SRC]entryIterator = from("Timesheet").where(entryExprs).queryIterator()

[MSG]The String 'Timesheet' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon357

[SRC]result = runService('createProjectTimesheet', ["userLogi.. : partyId])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon357

[SRC]result = runService('createProjectTimesheet', ["userLogi.. : partyId])

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString357

[SRC]result = runService('createProjectTimesheet', ["userLogi.. : partyId])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]result = runService('createProjectTimesheet', ["userLogi.. : partyId])

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString359

[SRC]timesheet = from("Timesheet").where("timesheetId", resul..).queryOne()

[MSG]The String 'Timesheet' can be wrapped in single quotes instead of double quotes

UnnecessaryGString359

[SRC]timesheet = from("Timesheet").where("timesheetId", resul..).queryOne()

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]context.partyNameView = from("PartyNameView").where("par..).queryOne()

[MSG]The String 'PartyNameView' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]context.partyNameView = from("PartyNameView").where("par..).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString370

[SRC]rateTypes = from("PartyRate").where("partyId", partyId, ...queryList()

[MSG]The String 'PartyRate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString370

[SRC]rateTypes = from("PartyRate").where("partyId", partyId, ...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString370

[SRC]rateTypes = from("PartyRate").where("partyId", partyId, ...queryList()

[MSG]The String 'defaultRate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString370

[SRC]rateTypes = from("PartyRate").where("partyId", partyId, ...queryList()

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon376

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The colon for the literal Map entry for key [timesheetId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString376

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon377

[SRC]leaveEntry = ["timesheetId" : timesheet.timesheetId]

[MSG]The colon for the literal Map entry for key [timesheetId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString377

[SRC]leaveEntry = ["timesheetId" : timesheet.timesheetId]

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator382

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator382

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator382

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator382

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator382

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator382

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator382

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator382

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator382

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator382

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator382

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator382

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator383

[SRC]pDay0Total = 0.00; pDay1Total=0.00; pDay2Total=0.00; pDa..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator383

[SRC]pDay0Total = 0.00; pDay1Total=0.00; pDay2Total=0.00; pDa..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator383

[SRC]pDay0Total = 0.00; pDay1Total=0.00; pDay2Total=0.00; pDa..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator383

[SRC]pDay0Total = 0.00; pDay1Total=0.00; pDay2Total=0.00; pDa..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator383

[SRC]pDay0Total = 0.00; pDay1Total=0.00; pDay2Total=0.00; pDa..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator383

[SRC]pDay0Total = 0.00; pDay1Total=0.00; pDay2Total=0.00; pDa..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator383

[SRC]pDay0Total = 0.00; pDay1Total=0.00; pDay2Total=0.00; pDa..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator383

[SRC]pDay0Total = 0.00; pDay1Total=0.00; pDay2Total=0.00; pDa..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator383

[SRC]pDay0Total = 0.00; pDay1Total=0.00; pDay2Total=0.00; pDa..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator383

[SRC]pDay0Total = 0.00; pDay1Total=0.00; pDay2Total=0.00; pDa..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator383

[SRC]pDay0Total = 0.00; pDay1Total=0.00; pDay2Total=0.00; pDa..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator383

[SRC]pDay0Total = 0.00; pDay1Total=0.00; pDay2Total=0.00; pDa..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

Indentation393

[SRC]entryWorkEffort = lastTimeEntry.getRelatedOne("WorkEffort", false)

[MSG]The statement on line 93 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

UnnecessaryGString393

[SRC]entryWorkEffort = lastTimeEntry.getRelatedOne("WorkEffort", false)

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

Indentation394

[SRC]if (entryWorkEffort) {

[MSG]The statement on line 94 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

Indentation395

[SRC]plannedHours = entryWorkEffort.getRelated("WorkEffortSki..null, false)

[MSG]The statement on line 95 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

UnnecessaryGString395

[SRC]plannedHours = entryWorkEffort.getRelated("WorkEffortSki..null, false)

[MSG]The String 'WorkEffortSkillStandard' can be wrapped in single quotes instead of double quotes

Indentation396

[SRC]pHours = 0.00

[MSG]The statement on line 96 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation397

[SRC]plannedHours.each { plannedHour ->

[MSG]The statement on line 97 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3102

[SRC]estimatedHour = 0.00

[MSG]The statement on line 102 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

TrailingWhitespace3103

[SRC]

[MSG]Line ends with whitespace characters

Indentation3104

[SRC]estimatedMilliSeconds = entryWorkEffort.estimatedMilliSeconds

[MSG]The statement on line 104 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3105

[SRC]if (estimatedMilliSeconds > 0)

[MSG]The statement on line 105 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

TrailingWhitespace3105

[SRC]if (estimatedMilliSeconds > 0)

[MSG]Line ends with whitespace characters

SpaceAroundOperator3106

[SRC]estimatedHour = estimatedMilliSeconds/3600000

[MSG]The operator "/" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3106

[SRC]estimatedHour = estimatedMilliSeconds/3600000

[MSG]The operator "/" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

Indentation3107

[SRC]entry.plannedHours = estimatedHour

[MSG]The statement on line 107 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3109

[SRC]planHours = 0.0

[MSG]The statement on line 109 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3110

[SRC]planHours = lastTimeEntry.planHours

[MSG]The statement on line 110 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3111

[SRC]lastTimeEntryOfTasks = from("TimeEntry").where("workEffo...queryList()

[MSG]The statement on line 111 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

UnnecessaryGString3111

[SRC]lastTimeEntryOfTasks = from("TimeEntry").where("workEffo...queryList()

[MSG]The String 'TimeEntry' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]lastTimeEntryOfTasks = from("TimeEntry").where("workEffo...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]lastTimeEntryOfTasks = from("TimeEntry").where("workEffo...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3111

[SRC]lastTimeEntryOfTasks = from("TimeEntry").where("workEffo...queryList()

[MSG]The String '-fromDate' can be wrapped in single quotes instead of double quotes

Indentation3112

[SRC]if (lastTimeEntryOfTasks.size() != 0) lastTimeEntry = la..ryOfTasks[0]

[MSG]The statement on line 112 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3113

[SRC]if (planHours < 1) {

[MSG]The statement on line 113 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3114

[SRC]planHours = estimatedHour

[MSG]The statement on line 114 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 17

Indentation3116

[SRC]entry.planHours = lastTimeEntry.planHours

[MSG]The statement on line 116 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3117

[SRC]actualHours = entryWorkEffort.getRelated("TimeEntry", nu..null, false)

[MSG]The statement on line 117 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

UnnecessaryGString3117

[SRC]actualHours = entryWorkEffort.getRelated("TimeEntry", nu..null, false)

[MSG]The String 'TimeEntry' can be wrapped in single quotes instead of double quotes

Indentation3118

[SRC]aHours = 0.00

[MSG]The statement on line 118 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3119

[SRC]actualHours.each { actualHour ->

[MSG]The statement on line 119 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3124

[SRC]entry.actualHours = aHours

[MSG]The statement on line 124 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3126

[SRC]workEffortPartyAssigns = EntityUtil.filterByDate(entryWo..ull, false))

[MSG]The statement on line 126 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

SpaceAroundMapEntryColon3126

[SRC]workEffortPartyAssigns = EntityUtil.filterByDate(entryWo..ull, false))

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3126

[SRC]workEffortPartyAssigns = EntityUtil.filterByDate(entryWo..ull, false))

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3126

[SRC]workEffortPartyAssigns = EntityUtil.filterByDate(entryWo..ull, false))

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

Indentation3127

[SRC]if (workEffortPartyAssigns) {

[MSG]The statement on line 127 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3128

[SRC]workEffortPartyAssign = workEffortPartyAssigns[0]

[MSG]The statement on line 128 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 17

Indentation3129

[SRC]entry.fromDate = workEffortPartyAssign.getTimestamp("fromDate")

[MSG]The statement on line 129 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 17

UnnecessaryGString3129

[SRC]entry.fromDate = workEffortPartyAssign.getTimestamp("fromDate")

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

Indentation3130

[SRC]entry.roleTypeId = workEffortPartyAssign.roleTypeId

[MSG]The statement on line 130 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 17

Indentation3131

[SRC]if ("SCAS_COMPLETED".equals(workEffortPartyAssign.statusId)) {

[MSG]The statement on line 131 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 17

UnnecessaryGString3131

[SRC]if ("SCAS_COMPLETED".equals(workEffortPartyAssign.statusId)) {

[MSG]The String 'SCAS_COMPLETED' can be wrapped in single quotes instead of double quotes

Indentation3132

[SRC]entry.checkComplete = "Y"

[MSG]The statement on line 132 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 17 but was 21

UnnecessaryGString3132

[SRC]entry.checkComplete = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

BlockEndsWithBlankLine3133

[MSG]Code block ends with a blank line.

TrailingWhitespace3133

[SRC]

[MSG]Line ends with whitespace characters

Indentation3136

[SRC]if ("STS_COMPLETED".equals(entryWorkEffort.currentStatusId)) {

[MSG]The statement on line 136 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 17

UnnecessaryGString3136

[SRC]if ("STS_COMPLETED".equals(entryWorkEffort.currentStatusId)) {

[MSG]The String 'STS_COMPLETED' can be wrapped in single quotes instead of double quotes

Indentation3137

[SRC]entry.checkComplete = "Y"

[MSG]The statement on line 137 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 17 but was 21

UnnecessaryGString3137

[SRC]entry.checkComplete = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

Indentation3142

[SRC]entry.workEffortId = entryWorkEffort.workEffortId

[MSG]The statement on line 142 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3143

[SRC]entry.workEffortName = entryWorkEffort.workEffortName

[MSG]The statement on line 143 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3144

[SRC]result = runService('getProjectInfoFromTask', ["userLogi..rkEffortId])

[MSG]The statement on line 144 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

SpaceAfterComma3144

[SRC]result = runService('getProjectInfoFromTask', ["userLogi..rkEffortId])

[MSG]The map entry taskId:entryWorkEffort.workEffortId within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundMapEntryColon3144

[SRC]result = runService('getProjectInfoFromTask', ["userLogi..rkEffortId])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3144

[SRC]result = runService('getProjectInfoFromTask', ["userLogi..rkEffortId])

[MSG]The colon for the literal Map entry for key [taskId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3144

[SRC]result = runService('getProjectInfoFromTask', ["userLogi..rkEffortId])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3144

[SRC]result = runService('getProjectInfoFromTask', ["userLogi..rkEffortId])

[MSG]The String 'taskId' can be wrapped in single quotes instead of double quotes

Indentation3145

[SRC]entry.phaseId = result.phaseId

[MSG]The statement on line 145 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 17

Indentation3146

[SRC]entry.phaseName = result.phaseName

[MSG]The statement on line 146 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 17

Indentation3147

[SRC]entry.projectId = result.projectId

[MSG]The statement on line 147 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 17

Indentation3148

[SRC]entry.projectName = result.projectName

[MSG]The statement on line 148 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 17

Indentation3149

[SRC]entry.taskWbsId = result.taskWbsId

[MSG]The statement on line 149 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 17

BlockEndsWithBlankLine3150

[MSG]Code block ends with a blank line.

Indentation3152

[SRC]entry.acualTotal = taskTotal

[MSG]The statement on line 152 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

Indentation3153

[SRC]entry.planTotal = planTotal

[MSG]The statement on line 153 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

Indentation3155

[SRC]if ("Y" != entry.checkComplete) {

[MSG]The statement on line 155 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

UnnecessaryGString3155

[SRC]if ("Y" != entry.checkComplete) {

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

Indentation3156

[SRC]if (aHours > 0.00)

[MSG]The statement on line 156 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3159

[SRC]entries.add(entry)

[MSG]The statement on line 159 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 17

Indentation3162

[SRC]taskTotal = 0.00

[MSG]The statement on line 162 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

Indentation3163

[SRC]planTotal = 0.00

[MSG]The statement on line 163 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

Indentation3164

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The statement on line 164 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

SpaceAroundMapEntryColon3164

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The colon for the literal Map entry for key [timesheetId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3164

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3167

[SRC]timeEntries = timesheet.getRelated("TimeEntry", null, ["..te"], false)

[MSG]The String 'TimeEntry' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3167

[SRC]timeEntries = timesheet.getRelated("TimeEntry", null, ["..te"], false)

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3167

[SRC]timeEntries = timesheet.getRelated("TimeEntry", null, ["..te"], false)

[MSG]The String 'rateTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3167

[SRC]timeEntries = timesheet.getRelated("TimeEntry", null, ["..te"], false)

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3171

[SRC]if (timeEntry!=void) {

[MSG]The operator "!=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3171

[SRC]if (timeEntry!=void) {

[MSG]The operator "!=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

Indentation3179

[SRC]retrieveWorkEffortData()

[MSG]The statement on line 179 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

SpaceAroundOperator3182

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3182

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator3182

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3182

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator3182

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3182

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

UnnecessaryGString3182

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The String 'd' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3185

[SRC]if ("d0".equals(dayNumber)) day0Total += hours

[MSG]The String 'd0' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3186

[SRC]if ("d1".equals(dayNumber)) day1Total += hours

[MSG]The String 'd1' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3187

[SRC]if ("d2".equals(dayNumber)) day2Total += hours

[MSG]The String 'd2' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3188

[SRC]if ("d3".equals(dayNumber)) day3Total += hours

[MSG]The String 'd3' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3189

[SRC]if ("d4".equals(dayNumber)) day4Total += hours

[MSG]The String 'd4' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3190

[SRC]if ("d5".equals(dayNumber)) day5Total += hours

[MSG]The String 'd5' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3191

[SRC]if ("d6".equals(dayNumber)) day6Total += hours

[MSG]The String 'd6' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3195

[SRC]dayNumber = "pd" + (timeEntry.fromDate.getTime() - times..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3195

[SRC]dayNumber = "pd" + (timeEntry.fromDate.getTime() - times..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator3195

[SRC]dayNumber = "pd" + (timeEntry.fromDate.getTime() - times..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3195

[SRC]dayNumber = "pd" + (timeEntry.fromDate.getTime() - times..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator3195

[SRC]dayNumber = "pd" + (timeEntry.fromDate.getTime() - times..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3195

[SRC]dayNumber = "pd" + (timeEntry.fromDate.getTime() - times..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

UnnecessaryGString3195

[SRC]dayNumber = "pd" + (timeEntry.fromDate.getTime() - times..*60*60*1000)

[MSG]The String 'pd' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3198

[SRC]if ("pd0".equals(dayNumber)) pDay0Total += planHours

[MSG]The String 'pd0' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3199

[SRC]if ("pd1".equals(dayNumber)) pDay1Total += planHours

[MSG]The String 'pd1' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3200

[SRC]if ("pd2".equals(dayNumber)) pDay2Total += planHours

[MSG]The String 'pd2' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3201

[SRC]if ("pd3".equals(dayNumber)) pDay3Total += planHours

[MSG]The String 'pd3' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3202

[SRC]if ("pd4".equals(dayNumber)) pDay4Total += planHours

[MSG]The String 'pd4' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3203

[SRC]if ("pd5".equals(dayNumber)) pDay5Total += planHours

[MSG]The String 'pd5' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3204

[SRC]if ("pd6".equals(dayNumber)) pDay6Total += planHours

[MSG]The String 'pd6' can be wrapped in single quotes instead of double quotes

BlockEndsWithBlankLine3206

[MSG]Code block ends with a blank line.

Indentation3212

[SRC]if (lastEmplLeaveEntry) {

[MSG]The statement on line 212 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

Indentation3214

[SRC]result = runService('getPartyLeaveHoursForDate',

[MSG]The statement on line 214 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

TrailingWhitespace3214

[SRC]result = runService('getPartyLeaveHoursForDate',

[MSG]Line ends with whitespace characters

UnnecessaryGString3215

[SRC]["userLogin": parameters.userLogin, "partyId": lastEmplL..y.fromDate])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3215

[SRC]["userLogin": parameters.userLogin, "partyId": lastEmplL..y.fromDate])

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3215

[SRC]["userLogin": parameters.userLogin, "partyId": lastEmplL..y.fromDate])

[MSG]The String 'leaveTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3215

[SRC]["userLogin": parameters.userLogin, "partyId": lastEmplL..y.fromDate])

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

Indentation3216

[SRC]if (result.hours) {

[MSG]The statement on line 216 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3217

[SRC]leaveEntry.plannedHours = result.hours

[MSG]The statement on line 217 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 17

Indentation3218

[SRC]leaveEntry.planHours = result.hours

[MSG]The statement on line 218 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 17

InvertedCondition3220

[SRC]if ("LEAVE_APPROVED" == lastEmplLeaveEntry.leaveStatus) {

[MSG]LEAVE_APPROVED is a constant expression on the left side of a compare equals operation

Indentation3220

[SRC]if ("LEAVE_APPROVED" == lastEmplLeaveEntry.leaveStatus) {

[MSG]The statement on line 220 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

UnnecessaryGString3220

[SRC]if ("LEAVE_APPROVED" == lastEmplLeaveEntry.leaveStatus) {

[MSG]The String 'LEAVE_APPROVED' can be wrapped in single quotes instead of double quotes

Indentation3221

[SRC]leaveEntry.checkComplete = "Y"

[MSG]The statement on line 221 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 17

UnnecessaryGString3221

[SRC]leaveEntry.checkComplete = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

Indentation3223

[SRC]leaveEntry.partyId = lastEmplLeaveEntry.partyId

[MSG]The statement on line 223 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3224

[SRC]leaveEntry.leaveTypeId = lastEmplLeaveEntry.leaveTypeId

[MSG]The statement on line 224 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3225

[SRC]leaveEntry.leavefromDate = lastEmplLeaveEntry.fromDate

[MSG]The statement on line 225 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3226

[SRC]leaveEntry.leavethruDate = lastEmplLeaveEntry.thruDate

[MSG]The statement on line 226 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3227

[SRC]leaveEntry.description = lastEmplLeaveEntry.description

[MSG]The statement on line 227 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3229

[SRC]leaveEntry.acualTotal = leaveTaskTotal

[MSG]The statement on line 229 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

Indentation3230

[SRC]leaveEntry.planHours = leavePlanTotal

[MSG]The statement on line 230 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

Indentation3231

[SRC]leaveEntry.actualHours = leaveTaskTotal

[MSG]The statement on line 231 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

Indentation3233

[SRC]entries.add(leaveEntry)

[MSG]The statement on line 233 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

Indentation3235

[SRC]leaveTaskTotal = 0.00

[MSG]The statement on line 235 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

Indentation3236

[SRC]leavePlanTotal = 0.00

[MSG]The statement on line 236 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

Indentation3237

[SRC]leaveEntry = ["timesheetId" : timesheet.timesheetId]

[MSG]The statement on line 237 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

SpaceAroundMapEntryColon3237

[SRC]leaveEntry = ["timesheetId" : timesheet.timesheetId]

[MSG]The colon for the literal Map entry for key [timesheetId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3237

[SRC]leaveEntry = ["timesheetId" : timesheet.timesheetId]

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3242

[SRC]leaveExprs.add(EntityCondition.makeCondition("fromDate",..t.fromDate))

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3243

[SRC]leaveExprs.add(EntityCondition.makeCondition("fromDate",..t.thruDate))

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3244

[SRC]leaveExprs.add(EntityCondition.makeCondition("partyId", ..S, partyId))

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3245

[SRC]emplLeave = from("EmplLeave").where(leaveExprs).cursorSc..ryIterator()

[MSG]The String 'EmplLeave' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3248

[SRC]if (emplLeaveEntry!=void) {

[MSG]The operator "!=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3248

[SRC]if (emplLeaveEntry!=void) {

[MSG]The operator "!=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

TrailingWhitespace3251

[SRC]

[MSG]Line ends with whitespace characters

TrailingWhitespace3253

[SRC]

[MSG]Line ends with whitespace characters

Indentation3257

[SRC]retrieveEmplLeaveData()

[MSG]The statement on line 257 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

TrailingWhitespace3259

[SRC]resultHours = runService('getPartyLeaveHoursForDate',

[MSG]Line ends with whitespace characters

UnnecessaryGString3260

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3260

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3260

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'leaveTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3260

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

TrailingWhitespace3261

[SRC]

[MSG]Line ends with whitespace characters

SpaceAroundOperator3263

[SRC]leaveDayNumber = "d" + (emplLeaveEntry.fromDate.getTime(..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3263

[SRC]leaveDayNumber = "d" + (emplLeaveEntry.fromDate.getTime(..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator3263

[SRC]leaveDayNumber = "d" + (emplLeaveEntry.fromDate.getTime(..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3263

[SRC]leaveDayNumber = "d" + (emplLeaveEntry.fromDate.getTime(..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator3263

[SRC]leaveDayNumber = "d" + (emplLeaveEntry.fromDate.getTime(..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3263

[SRC]leaveDayNumber = "d" + (emplLeaveEntry.fromDate.getTime(..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

UnnecessaryGString3263

[SRC]leaveDayNumber = "d" + (emplLeaveEntry.fromDate.getTime(..*60*60*1000)

[MSG]The String 'd' can be wrapped in single quotes instead of double quotes

TrailingWhitespace3264

[SRC]resultHours = runService('getPartyLeaveHoursForDate',

[MSG]Line ends with whitespace characters

UnnecessaryGString3265

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3265

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3265

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'leaveTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3265

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3268

[SRC]if ("d0".equals(leaveDayNumber)) day0Total += leaveHours

[MSG]The String 'd0' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3269

[SRC]if ("d1".equals(leaveDayNumber)) day1Total += leaveHours

[MSG]The String 'd1' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3270

[SRC]if ("d2".equals(leaveDayNumber)) day2Total += leaveHours

[MSG]The String 'd2' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3271

[SRC]if ("d3".equals(leaveDayNumber)) day3Total += leaveHours

[MSG]The String 'd3' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3272

[SRC]if ("d4".equals(leaveDayNumber)) day4Total += leaveHours

[MSG]The String 'd4' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3273

[SRC]if ("d5".equals(leaveDayNumber)) day5Total += leaveHours

[MSG]The String 'd5' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3274

[SRC]if ("d6".equals(leaveDayNumber)) day6Total += leaveHours

[MSG]The String 'd6' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3278

[SRC]leavePlanDay = "pd" + (emplLeaveEntry.fromDate.getTime()..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3278

[SRC]leavePlanDay = "pd" + (emplLeaveEntry.fromDate.getTime()..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator3278

[SRC]leavePlanDay = "pd" + (emplLeaveEntry.fromDate.getTime()..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3278

[SRC]leavePlanDay = "pd" + (emplLeaveEntry.fromDate.getTime()..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator3278

[SRC]leavePlanDay = "pd" + (emplLeaveEntry.fromDate.getTime()..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3278

[SRC]leavePlanDay = "pd" + (emplLeaveEntry.fromDate.getTime()..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

UnnecessaryGString3278

[SRC]leavePlanDay = "pd" + (emplLeaveEntry.fromDate.getTime()..*60*60*1000)

[MSG]The String 'pd' can be wrapped in single quotes instead of double quotes

TrailingWhitespace3279

[SRC]resultPlanHours = runService('getPartyLeaveHoursForDate',

[MSG]Line ends with whitespace characters

UnnecessaryGString3280

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3280

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3280

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'leaveTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3280

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3283

[SRC]if ("pd0".equals(leavePlanDay)) pDay0Total += leavePlanHours

[MSG]The String 'pd0' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3284

[SRC]if ("pd1".equals(leavePlanDay)) pDay1Total += leavePlanHours

[MSG]The String 'pd1' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3285

[SRC]if ("pd2".equals(leavePlanDay)) pDay2Total += leavePlanHours

[MSG]The String 'pd2' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3286

[SRC]if ("pd3".equals(leavePlanDay)) pDay3Total += leavePlanHours

[MSG]The String 'pd3' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3287

[SRC]if ("pd4".equals(leavePlanDay)) pDay4Total += leavePlanHours

[MSG]The String 'pd4' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3288

[SRC]if ("pd5".equals(leavePlanDay)) pDay5Total += leavePlanHours

[MSG]The String 'pd5' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3289

[SRC]if ("pd6".equals(leavePlanDay)) pDay6Total += leavePlanHours

[MSG]The String 'pd6' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3292

[SRC]leaveEntry.rateTypeId = "STANDARD"

[MSG]The String 'STANDARD' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3306

[SRC]if (!"TIMESHEET_COMPLETED".equals(timesheet.statusId)) {

[MSG]The String 'TIMESHEET_COMPLETED' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3307

[SRC]for (c=0; c < 3; c++) { // add empty lines

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3307

[SRC]for (c=0; c < 3; c++) { // add empty lines

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundMapEntryColon3308

[SRC]entries.add(["timesheetId" : timesheet.timesheetId])

[MSG]The colon for the literal Map entry for key [timesheetId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3308

[SRC]entries.add(["timesheetId" : timesheet.timesheetId])

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon3314

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The colon for the literal Map entry for key [timesheetId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3314

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

UnnecessaryObjectReferences3323

[SRC]entry.pd1 = pDay1Total

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3324

[SRC]entry.pd2 = pDay2Total

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3325

[SRC]entry.pd3 = pDay3Total

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3326

[SRC]entry.pd4 = pDay4Total

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3327

[SRC]entry.pd5 = pDay5Total

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3328

[SRC]entry.pd6 = pDay6Total

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3329

[SRC]entry.phaseName = uiLabelMap.ScrumTotals

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryGString3330

[SRC]entry.workEffortId = "Totals"

[MSG]The String 'Totals' can be wrapped in single quotes instead of double quotes

UnnecessaryObjectReferences3330

[SRC]entry.workEffortId = "Totals"

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3331

[SRC]entry.total = day0Total + day1Total + day2Total + day3To.. + day6Total

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryGString3336

[SRC]timesheetsDb = from("Timesheet").where("partyId", partyI...queryList()

[MSG]The String 'Timesheet' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3336

[SRC]timesheetsDb = from("Timesheet").where("partyId", partyI...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3336

[SRC]timesheetsDb = from("Timesheet").where("partyId", partyI...queryList()

[MSG]The String 'fromDate DESC' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3342

[SRC]leaveExprsList.add(EntityCondition.makeCondition("fromDa..b.fromDate))

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3343

[SRC]leaveExprsList.add(EntityCondition.makeCondition("fromDa..b.thruDate))

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3344

[SRC]leaveExprsList.add(EntityCondition.makeCondition("partyI..S, partyId))

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3345

[SRC]emplLeaveList = from("EmplLeave").where(leaveExprsList)...ryIterator()

[MSG]The String 'EmplLeave' can be wrapped in single quotes instead of double quotes

TrailingWhitespace3347

[SRC]

[MSG]Line ends with whitespace characters

TrailingWhitespace3350

[SRC]resultHour = runService('getPartyLeaveHoursForDate',

[MSG]Line ends with whitespace characters

UnnecessaryGString3351

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3351

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3351

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'leaveTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3351

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3360

[SRC]entries = timesheetDb.getRelated("TimeEntry", null, null, false)

[MSG]The String 'TimeEntry' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3375

[SRC]taskList=[]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3375

[SRC]taskList=[]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAfterComma3378

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The parameter taskActualStartDate DESC in the call to method orderBy within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma3378

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The map entry taskCurrentStatusId:STS_CREATED within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundMapEntryColon3378

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The colon for the literal Map entry for key [sprintTypeId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3378

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The colon for the literal Map entry for key [taskCurrentStatusId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3378

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The String 'ProjectSprintBacklogAndTask' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3378

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The String 'sprintTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3378

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The String 'SCRUM_SPRINT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3378

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The String 'taskCurrentStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3378

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The String 'STS_CREATED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3378

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The String 'projectName ASC' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3378

[SRC]projectAndTaskList = from("ProjectSprintBacklogAndTask")...queryList()

[MSG]The String 'taskActualStartDate DESC' can be wrapped in single quotes instead of double quotes

Indentation3380

[SRC]userLoginId = userLogin.partyId

[MSG]The statement on line 380 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [5, 9, 13] or one of [23, 27, 31] columns, but was 1

UnnecessaryGString3382

[SRC]workEffortList = from("WorkEffortAndProduct").where("wor...queryList()

[MSG]The String 'WorkEffortAndProduct' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3382

[SRC]workEffortList = from("WorkEffortAndProduct").where("wor...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

NoTabCharacter3384

[MSG]The tab character is not allowed in source files

TrailingWhitespace3384

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString3385

[SRC]partyAssignmentSprintList = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3385

[SRC]partyAssignmentSprintList = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3385

[SRC]partyAssignmentSprintList = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3390

[SRC]partyAssignmentTaskList = from("WorkEffortPartyAssignmen...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3390

[SRC]partyAssignmentTaskList = from("WorkEffortPartyAssignmen...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

Indentation3395

[SRC]backlogStatusId = projectAndTaskMap.backlogStatusId

[MSG]The statement on line 395 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [13, 17, 21] but was 4

Indentation3396

[SRC]if ("RF_SCRUM_MEETINGS".equals(custRequestTypeId) && "CR..StatusId)) {

[MSG]The statement on line 396 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [13, 17, 21] but was 4

UnnecessaryGString3396

[SRC]if ("RF_SCRUM_MEETINGS".equals(custRequestTypeId) && "CR..StatusId)) {

[MSG]The String 'RF_SCRUM_MEETINGS' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3396

[SRC]if ("RF_SCRUM_MEETINGS".equals(custRequestTypeId) && "CR..StatusId)) {

[MSG]The String 'CRQ_REVIEWED' can be wrapped in single quotes instead of double quotes

Indentation3397

[SRC]projectSprintBacklogAndTaskList.add(projectAndTaskMap)

[MSG]The statement on line 397 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 5

Indentation3400

[SRC]projectSprintBacklogAndTaskList.add(0,projectAndTaskMap)

[MSG]The statement on line 400 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [13, 17, 21] but was 6

SpaceAfterComma3400

[SRC]projectSprintBacklogAndTaskList.add(0,projectAndTaskMap)

[MSG]The parameter projectAndTaskMap in the call to method add within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3406

[SRC]unplanList=[]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3406

[SRC]unplanList=[]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAfterComma3409

[SRC]custRequestList = from("CustRequest").where("custRequest...queryList()

[MSG]The parameter statusId in the call to method where within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString3409

[SRC]custRequestList = from("CustRequest").where("custRequest...queryList()

[MSG]The String 'CustRequest' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3409

[SRC]custRequestList = from("CustRequest").where("custRequest...queryList()

[MSG]The String 'custRequestTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3409

[SRC]custRequestList = from("CustRequest").where("custRequest...queryList()

[MSG]The String 'RF_UNPLAN_BACKLOG' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3409

[SRC]custRequestList = from("CustRequest").where("custRequest...queryList()

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3409

[SRC]custRequestList = from("CustRequest").where("custRequest...queryList()

[MSG]The String 'CRQ_REVIEWED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3409

[SRC]custRequestList = from("CustRequest").where("custRequest...queryList()

[MSG]The String 'custRequestDate DESC' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3412

[SRC]custRequestItemList = custRequestMap.getRelated("CustReq..null, false)

[MSG]The String 'CustRequestItem' can be wrapped in single quotes instead of double quotes

Indentation3413

[SRC]custRequestItem =

[MSG]The statement on line 413 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [13, 17, 21] or one of [28, 32, 36] columns, but was 4

TrailingWhitespace3413

[SRC]custRequestItem =

[MSG]Line ends with whitespace characters

Indentation3415

[SRC]product = from("Product").where("productId", productOut).queryOne()

[MSG]The statement on line 415 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [13, 17, 21] or one of [28, 32, 36] columns, but was 4

UnnecessaryGString3415

[SRC]product = from("Product").where("productId", productOut).queryOne()

[MSG]The String 'Product' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3415

[SRC]product = from("Product").where("productId", productOut).queryOne()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3419

[SRC]custRequestWorkEffortList = from("CustRequestWorkEffort"...queryList()

[MSG]The String 'CustRequestWorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3419

[SRC]custRequestWorkEffortList = from("CustRequestWorkEffort"...queryList()

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3421

[SRC]partyAssignmentTaskList = from("WorkEffortPartyAssignmen...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3421

[SRC]partyAssignmentTaskList = from("WorkEffortPartyAssignmen...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3426

[SRC]workEffortMap = from("WorkEffort").where("workEffortId",..).queryOne()

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3426

[SRC]workEffortMap = from("WorkEffort").where("workEffortId",..).queryOne()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

Indentation3431

[SRC]result.custRequestTypeId = custRequestMap.custRequestTypeId

[MSG]The statement on line 431 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [29, 33, 37] but was 8

Indentation3432

[SRC]result.taskTypeId = workEffortMap.workEffortTypeId

[MSG]The statement on line 432 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [29, 33, 37] but was 8

SpaceAfterComma3441

[SRC]projectSprintBacklogAndTaskList = UtilMisc.sortMaps(proj..RequestId"])

[MSG]The list element sprintName within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma3441

[SRC]projectSprintBacklogAndTaskList = UtilMisc.sortMaps(proj..RequestId"])

[MSG]The list element -taskTypeId within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma3441

[SRC]projectSprintBacklogAndTaskList = UtilMisc.sortMaps(proj..RequestId"])

[MSG]The list element custRequestId within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString3441

[SRC]projectSprintBacklogAndTaskList = UtilMisc.sortMaps(proj..RequestId"])

[MSG]The String 'projectName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3441

[SRC]projectSprintBacklogAndTaskList = UtilMisc.sortMaps(proj..RequestId"])

[MSG]The String 'sprintName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3441

[SRC]projectSprintBacklogAndTaskList = UtilMisc.sortMaps(proj..RequestId"])

[MSG]The String '-taskTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3441

[SRC]projectSprintBacklogAndTaskList = UtilMisc.sortMaps(proj..RequestId"])

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

Indentation3443

[SRC]blTypeId = projectSprintBacklogAndTaskMap.custRequestTypeId

[MSG]The statement on line 443 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [5, 9, 13] or one of [36, 40, 44] columns, but was 2

Indentation3444

[SRC]if (blTypeId == "RF_SCRUM_MEETINGS"){

[MSG]The statement on line 444 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [5, 9, 13] or one of [36, 40, 44] columns, but was 2

SpaceBeforeOpeningBrace3444

[SRC]if (blTypeId == "RF_SCRUM_MEETINGS"){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString3444

[SRC]if (blTypeId == "RF_SCRUM_MEETINGS"){

[MSG]The String 'RF_SCRUM_MEETINGS' can be wrapped in single quotes instead of double quotes

Indentation3445

[SRC]taskList.add(projectSprintBacklogAndTaskMap)

[MSG]The statement on line 445 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [9, 13, 17] but was 3

SpaceAfterComma3448

[SRC]projectSprintBacklogAndTaskList = UtilMisc.sortMaps(proj..RequestId"])

[MSG]The list element sprintName within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma3448

[SRC]projectSprintBacklogAndTaskList = UtilMisc.sortMaps(proj..RequestId"])

[MSG]The list element -taskTypeId within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma3448

[SRC]projectSprintBacklogAndTaskList = UtilMisc.sortMaps(proj..RequestId"])

[MSG]The list element custRequestId within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString3448

[SRC]projectSprintBacklogAndTaskList = UtilMisc.sortMaps(proj..RequestId"])

[MSG]The String '-projectName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3448

[SRC]projectSprintBacklogAndTaskList = UtilMisc.sortMaps(proj..RequestId"])

[MSG]The String 'sprintName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3448

[SRC]projectSprintBacklogAndTaskList = UtilMisc.sortMaps(proj..RequestId"])

[MSG]The String '-taskTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3448

[SRC]projectSprintBacklogAndTaskList = UtilMisc.sortMaps(proj..RequestId"])

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

Indentation3450

[SRC]blTypeId = projectSprintBacklogAndTaskMap.custRequestTypeId

[MSG]The statement on line 450 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [5, 9, 13] or one of [36, 40, 44] columns, but was 2

InvertedCondition3451

[SRC]if ("RF_PROD_BACKLOG" == blTypeId){

[MSG]RF_PROD_BACKLOG is a constant expression on the left side of a compare equals operation

Indentation3451

[SRC]if ("RF_PROD_BACKLOG" == blTypeId){

[MSG]The statement on line 451 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [5, 9, 13] or one of [36, 40, 44] columns, but was 2

SpaceBeforeOpeningBrace3451

[SRC]if ("RF_PROD_BACKLOG" == blTypeId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString3451

[SRC]if ("RF_PROD_BACKLOG" == blTypeId){

[MSG]The String 'RF_PROD_BACKLOG' can be wrapped in single quotes instead of double quotes

Indentation3452

[SRC]taskList.add(0,projectSprintBacklogAndTaskMap)

[MSG]The statement on line 452 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [9, 13, 17] but was 3

SpaceAfterComma3452

[SRC]taskList.add(0,projectSprintBacklogAndTaskMap)

[MSG]The parameter projectSprintBacklogAndTaskMap in the call to method add within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma3455

[SRC]unplanList = UtilMisc.sortMaps(unplanList,["-productName..RequestId"])

[MSG]The parameter [-productName, -taskTypeId, custRequestId] in the call to method sortMaps within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma3455

[SRC]unplanList = UtilMisc.sortMaps(unplanList,["-productName..RequestId"])

[MSG]The list element -taskTypeId within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma3455

[SRC]unplanList = UtilMisc.sortMaps(unplanList,["-productName..RequestId"])

[MSG]The list element custRequestId within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString3455

[SRC]unplanList = UtilMisc.sortMaps(unplanList,["-productName..RequestId"])

[MSG]The String '-productName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3455

[SRC]unplanList = UtilMisc.sortMaps(unplanList,["-productName..RequestId"])

[MSG]The String '-taskTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3455

[SRC]unplanList = UtilMisc.sortMaps(unplanList,["-productName..RequestId"])

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

SpaceAroundClosureArrow3456

[SRC]unplanList.each { unplanMap->

[MSG]The closure arrow (->) within class org.apache.ofbiz.scrum.None is not surrounded by a space or whitespace

Indentation3457

[SRC]taskList.add(0,unplanMap)

[MSG]The statement on line 457 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [5, 9, 13] or one of [15, 19, 23] columns, but was 3

SpaceAfterComma3457

[SRC]taskList.add(0,unplanMap)

[MSG]The parameter unplanMap in the call to method add within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

➥ EditWeekTimesheet.groovy

Rule NamePriorityLine #Source Line / Message
IfStatementBraces261

[SRC]if (!timesheet) return

[MSG]The if statement lacks braces

LineLength2103

[SRC]workEffortPartyAssigns = EntityUtil.filterByDate(entryWo..ull, false))

[MSG]The line exceeds 150 characters. The line is 153 characters.

ExplicitCallToEqualsMethod2108

[SRC]if ("PAS_COMPLETED".equals(workEffortPartyAssign.statusId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to PAS_COMPLETED.equals(workEffortPartyAssign.statusId) method can be rewritten as (PAS_COMPLETED == (workEffortPartyAssign.statusId))

ExplicitCallToEqualsMethod2142

[SRC](!lastTimeEntry.workEffortId.equals(timeEntry.workEffortId) ||

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to lastTimeEntry.workEffortId.equals(timeEntry.workEffortId) method can be rewritten as (lastTimeEntry.workEffortId == (timeEntry.workEffortId))

ExplicitCallToEqualsMethod2143

[SRC]!lastTimeEntry.rateTypeId.equals(timeEntry.rateTypeId))) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to lastTimeEntry.rateTypeId.equals(timeEntry.rateTypeId) method can be rewritten as (lastTimeEntry.rateTypeId == (timeEntry.rateTypeId))

IfStatementBraces2150

[SRC]if ("d0".equals(dayNumber)) day0Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2150

[SRC]if ("d0".equals(dayNumber)) day0Total += hours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d0.equals(dayNumber) method can be rewritten as (d0 == (dayNumber))

IfStatementBraces2151

[SRC]if ("d1".equals(dayNumber)) day1Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2151

[SRC]if ("d1".equals(dayNumber)) day1Total += hours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d1.equals(dayNumber) method can be rewritten as (d1 == (dayNumber))

IfStatementBraces2152

[SRC]if ("d2".equals(dayNumber)) day2Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2152

[SRC]if ("d2".equals(dayNumber)) day2Total += hours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d2.equals(dayNumber) method can be rewritten as (d2 == (dayNumber))

IfStatementBraces2153

[SRC]if ("d3".equals(dayNumber)) day3Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2153

[SRC]if ("d3".equals(dayNumber)) day3Total += hours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d3.equals(dayNumber) method can be rewritten as (d3 == (dayNumber))

IfStatementBraces2154

[SRC]if ("d4".equals(dayNumber)) day4Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2154

[SRC]if ("d4".equals(dayNumber)) day4Total += hours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d4.equals(dayNumber) method can be rewritten as (d4 == (dayNumber))

IfStatementBraces2155

[SRC]if ("d5".equals(dayNumber)) day5Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2155

[SRC]if ("d5".equals(dayNumber)) day5Total += hours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d5.equals(dayNumber) method can be rewritten as (d5 == (dayNumber))

IfStatementBraces2156

[SRC]if ("d6".equals(dayNumber)) day6Total += hours

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod2156

[SRC]if ("d6".equals(dayNumber)) day6Total += hours

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to d6.equals(dayNumber) method can be rewritten as (d6 == (dayNumber))

ExplicitCallToEqualsMethod2168

[SRC]if (!"TIMESHEET_COMPLETED".equals(timesheet.statusId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to TIMESHEET_COMPLETED.equals(timesheet.statusId) method can be rewritten as (TIMESHEET_COMPLETED == (timesheet.statusId))

ExplicitLinkedListInstantiation2192

[SRC]timesheets = new LinkedList()

[MSG]LinkedList objects are better instantiated using the form "[] as Queue"

NoWildcardImports321

[SRC]import java.util.*

[MSG]Wildcard (star) import

UnnecessaryGroovyImport321

[SRC]import java.util.*

NoWildcardImports322

[SRC]import java.lang.*

[MSG]Wildcard (star) import

UnnecessaryGroovyImport322

[SRC]import java.lang.*

UnnecessaryGString330

[SRC]uiLabelMap = UtilProperties.getResourceBundleMap("scrumU..ls", locale)

[MSG]The String 'scrumUiLabels' can be wrapped in single quotes instead of double quotes

CouldBeElvis333

[SRC]if (!partyId) {

[MSG]Code could use elvis operator: partyId = partyId ?: parameters.userLogin.partyId

UnnecessaryGString341

[SRC]timesheet = from("Timesheet").where("timesheetId", times..).queryOne()

[MSG]The String 'Timesheet' can be wrapped in single quotes instead of double quotes

UnnecessaryGString341

[SRC]timesheet = from("Timesheet").where("timesheetId", times..).queryOne()

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

SpaceAfterComma345

[SRC]midweek = UtilDateTime.addDaysToTimestamp(UtilDateTime.g..estamp()),3)

[MSG]The parameter 3 in the call to method addDaysToTimestamp within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString347

[SRC]EntityCondition.makeCondition("fromDate", EntityComparis..N, midweek),

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString348

[SRC]EntityCondition.makeCondition("thruDate", EntityComparis..N, midweek),

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]EntityCondition.makeCondition("partyId", EntityCompariso..LS, partyId)

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString351

[SRC]entryIterator = from("Timesheet").where(entryExprs).queryIterator()

[MSG]The String 'Timesheet' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon355

[SRC]result = runService('createProjectTimesheet', ["userLogi.. : partyId])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon355

[SRC]result = runService('createProjectTimesheet', ["userLogi.. : partyId])

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString355

[SRC]result = runService('createProjectTimesheet', ["userLogi.. : partyId])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]result = runService('createProjectTimesheet', ["userLogi.. : partyId])

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]timesheet = from("Timesheet").where("timesheetId", resul..).queryOne()

[MSG]The String 'Timesheet' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]timesheet = from("Timesheet").where("timesheetId", resul..).queryOne()

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString366

[SRC]context.partyNameView = from("PartyNameView").where("par..).queryOne()

[MSG]The String 'PartyNameView' can be wrapped in single quotes instead of double quotes

UnnecessaryGString366

[SRC]context.partyNameView = from("PartyNameView").where("par..).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]rateTypes = from("PartyRate").where("partyId", partyId, ...queryList()

[MSG]The String 'PartyRate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]rateTypes = from("PartyRate").where("partyId", partyId, ...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]rateTypes = from("PartyRate").where("partyId", partyId, ...queryList()

[MSG]The String 'defaultRate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]rateTypes = from("PartyRate").where("partyId", partyId, ...queryList()

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon374

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The colon for the literal Map entry for key [timesheetId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString374

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator376

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator376

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator376

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator376

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator376

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator376

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator376

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator376

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator376

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator376

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator376

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator376

[SRC]day0Total = 0.00; day1Total=0.00; day2Total=0.00; day3To..y6Total=0.00

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

Indentation384

[SRC]entryWorkEffort = lastTimeEntry.getRelatedOne("WorkEffort", false)

[MSG]The statement on line 84 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

UnnecessaryGString384

[SRC]entryWorkEffort = lastTimeEntry.getRelatedOne("WorkEffort", false)

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

Indentation385

[SRC]if (entryWorkEffort) {

[MSG]The statement on line 85 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

Indentation386

[SRC]plannedHours = entryWorkEffort.getRelated("WorkEffortSki..null, false)

[MSG]The statement on line 86 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

UnnecessaryGString386

[SRC]plannedHours = entryWorkEffort.getRelated("WorkEffortSki..null, false)

[MSG]The String 'WorkEffortSkillStandard' can be wrapped in single quotes instead of double quotes

Indentation387

[SRC]pHours = 0.00

[MSG]The statement on line 87 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation388

[SRC]plannedHours.each { plannedHour ->

[MSG]The statement on line 88 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation393

[SRC]entry.plannedHours = pHours

[MSG]The statement on line 93 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation394

[SRC]actualHours = entryWorkEffort.getRelated("TimeEntry", nu..null, false)

[MSG]The statement on line 94 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

UnnecessaryGString394

[SRC]actualHours = entryWorkEffort.getRelated("TimeEntry", nu..null, false)

[MSG]The String 'TimeEntry' can be wrapped in single quotes instead of double quotes

Indentation395

[SRC]aHours = 0.00

[MSG]The statement on line 95 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation396

[SRC]actualHours.each { actualHour ->

[MSG]The statement on line 96 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3101

[SRC]entry.actualHours = aHours

[MSG]The statement on line 101 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3103

[SRC]workEffortPartyAssigns = EntityUtil.filterByDate(entryWo..ull, false))

[MSG]The statement on line 103 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

SpaceAroundMapEntryColon3103

[SRC]workEffortPartyAssigns = EntityUtil.filterByDate(entryWo..ull, false))

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3103

[SRC]workEffortPartyAssigns = EntityUtil.filterByDate(entryWo..ull, false))

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3103

[SRC]workEffortPartyAssigns = EntityUtil.filterByDate(entryWo..ull, false))

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

Indentation3104

[SRC]if (workEffortPartyAssigns) {

[MSG]The statement on line 104 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3105

[SRC]workEffortPartyAssign = workEffortPartyAssigns[0]

[MSG]The statement on line 105 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 17

Indentation3106

[SRC]entry.fromDate = workEffortPartyAssign.getTimestamp("fromDate")

[MSG]The statement on line 106 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 17

UnnecessaryGString3106

[SRC]entry.fromDate = workEffortPartyAssign.getTimestamp("fromDate")

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

Indentation3107

[SRC]entry.roleTypeId = workEffortPartyAssign.roleTypeId

[MSG]The statement on line 107 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 17

Indentation3108

[SRC]if ("PAS_COMPLETED".equals(workEffortPartyAssign.statusId)) {

[MSG]The statement on line 108 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 17

UnnecessaryGString3108

[SRC]if ("PAS_COMPLETED".equals(workEffortPartyAssign.statusId)) {

[MSG]The String 'PAS_COMPLETED' can be wrapped in single quotes instead of double quotes

Indentation3109

[SRC]entry.checkComplete = "Y"

[MSG]The statement on line 109 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 17 but was 21

UnnecessaryGString3109

[SRC]entry.checkComplete = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

Indentation3114

[SRC]entry.workEffortId = entryWorkEffort.workEffortId

[MSG]The statement on line 114 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3115

[SRC]entry.workEffortName = entryWorkEffort.workEffortName

[MSG]The statement on line 115 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

Indentation3116

[SRC]result = runService('getProjectIdAndNameFromTask', ["use..rkEffortId])

[MSG]The statement on line 116 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

SpaceAfterComma3116

[SRC]result = runService('getProjectIdAndNameFromTask', ["use..rkEffortId])

[MSG]The map entry taskId:entryWorkEffort.workEffortId within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundMapEntryColon3116

[SRC]result = runService('getProjectIdAndNameFromTask', ["use..rkEffortId])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3116

[SRC]result = runService('getProjectIdAndNameFromTask', ["use..rkEffortId])

[MSG]The colon for the literal Map entry for key [taskId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3116

[SRC]result = runService('getProjectIdAndNameFromTask', ["use..rkEffortId])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3116

[SRC]result = runService('getProjectIdAndNameFromTask', ["use..rkEffortId])

[MSG]The String 'taskId' can be wrapped in single quotes instead of double quotes

Indentation3117

[SRC]entry.sprintId = result.phaseId

[MSG]The statement on line 117 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 17

Indentation3118

[SRC]entry.sprintName = result.phaseName

[MSG]The statement on line 118 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 17

Indentation3119

[SRC]entry.projectId = result.projectId

[MSG]The statement on line 119 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 17

Indentation3120

[SRC]entry.projectName = result.projectName

[MSG]The statement on line 120 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 17

Indentation3121

[SRC]entry.taskWbsId = result.taskWbsId

[MSG]The statement on line 121 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 17

BlockEndsWithBlankLine3122

[MSG]Code block ends with a blank line.

Indentation3124

[SRC]entry.total = taskTotal

[MSG]The statement on line 124 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

Indentation3126

[SRC]entries.add(entry)

[MSG]The statement on line 126 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

Indentation3128

[SRC]taskTotal = 0.00

[MSG]The statement on line 128 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

Indentation3129

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The statement on line 129 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

SpaceAroundMapEntryColon3129

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The colon for the literal Map entry for key [timesheetId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3129

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3132

[SRC]timeEntries = timesheet.getRelated("TimeEntry", null, ["..te"], false)

[MSG]The String 'TimeEntry' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3132

[SRC]timeEntries = timesheet.getRelated("TimeEntry", null, ["..te"], false)

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3132

[SRC]timeEntries = timesheet.getRelated("TimeEntry", null, ["..te"], false)

[MSG]The String 'rateTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3132

[SRC]timeEntries = timesheet.getRelated("TimeEntry", null, ["..te"], false)

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3136

[SRC]if (timeEntry!=void) {

[MSG]The operator "!=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3136

[SRC]if (timeEntry!=void) {

[MSG]The operator "!=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

Indentation3144

[SRC]retrieveWorkEffortData()

[MSG]The statement on line 144 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 13

SpaceAroundOperator3147

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3147

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator3147

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3147

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator3147

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3147

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The operator "*" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

UnnecessaryGString3147

[SRC]dayNumber = "d" + (timeEntry.fromDate.getTime() - timesh..*60*60*1000)

[MSG]The String 'd' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3150

[SRC]if ("d0".equals(dayNumber)) day0Total += hours

[MSG]The String 'd0' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3151

[SRC]if ("d1".equals(dayNumber)) day1Total += hours

[MSG]The String 'd1' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3152

[SRC]if ("d2".equals(dayNumber)) day2Total += hours

[MSG]The String 'd2' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3153

[SRC]if ("d3".equals(dayNumber)) day3Total += hours

[MSG]The String 'd3' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3154

[SRC]if ("d4".equals(dayNumber)) day4Total += hours

[MSG]The String 'd4' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3155

[SRC]if ("d5".equals(dayNumber)) day5Total += hours

[MSG]The String 'd5' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3156

[SRC]if ("d6".equals(dayNumber)) day6Total += hours

[MSG]The String 'd6' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3168

[SRC]if (!"TIMESHEET_COMPLETED".equals(timesheet.statusId)) {

[MSG]The String 'TIMESHEET_COMPLETED' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3169

[SRC]for (c=0; c < 3; c++) { // add empty lines

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3169

[SRC]for (c=0; c < 3; c++) { // add empty lines

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundMapEntryColon3170

[SRC]entries.add(["timesheetId" : timesheet.timesheetId])

[MSG]The colon for the literal Map entry for key [timesheetId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3170

[SRC]entries.add(["timesheetId" : timesheet.timesheetId])

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon3176

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The colon for the literal Map entry for key [timesheetId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3176

[SRC]entry = ["timesheetId" : timesheet.timesheetId]

[MSG]The String 'timesheetId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3185

[SRC]entry.workEffortId = "Totals"

[MSG]The String 'Totals' can be wrapped in single quotes instead of double quotes

UnnecessaryObjectReferences3185

[SRC]entry.workEffortId = "Totals"

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3186

[SRC]entry.total = day0Total + day1Total + day2Total + day3To.. + day6Total

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryGString3191

[SRC]timesheetsDb = from("Timesheet").where("partyId", partyI...queryList()

[MSG]The String 'Timesheet' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3191

[SRC]timesheetsDb = from("Timesheet").where("partyId", partyI...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3191

[SRC]timesheetsDb = from("Timesheet").where("partyId", partyI...queryList()

[MSG]The String 'fromDate DESC' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3196

[SRC]entries = timesheetDb.getRelated("TimeEntry", null, null, false)

[MSG]The String 'TimeEntry' can be wrapped in single quotes instead of double quotes

➥ FindBacklogItem.groovy

Rule NamePriorityLine #Source Line / Message
LineLength242

[SRC]int countImplTask=0, countImplTaskComplete=0, countInsta..ntTestTask=0

[MSG]The line exceeds 150 characters. The line is 157 characters.

SpaceAroundOperator325

[SRC]productId =parameters.productId

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator326

[SRC]backlogList=[]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator326

[SRC]backlogList=[]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

UnnecessaryGString327

[SRC]custRequestList = from("CustRequestItem").where("product...queryList()

[MSG]The String 'CustRequestItem' can be wrapped in single quotes instead of double quotes

UnnecessaryGString327

[SRC]custRequestList = from("CustRequestItem").where("product...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator329

[SRC]custRequestId=custRequestListMap.custRequestId

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator329

[SRC]custRequestId=custRequestListMap.custRequestId

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

UnnecessaryGString331

[SRC]exprBldr.add(EntityCondition.makeCondition("statusId", E.._REOPENED"))

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString331

[SRC]exprBldr.add(EntityCondition.makeCondition("statusId", E.._REOPENED"))

[MSG]The String 'CRQ_REOPENED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]exprBldr.add(EntityCondition.makeCondition("statusId", E.._REVIEWED"))

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]exprBldr.add(EntityCondition.makeCondition("statusId", E.._REVIEWED"))

[MSG]The String 'CRQ_REVIEWED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]andExprs.add(EntityCondition.makeCondition("custRequestI..tRequestId))

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]orderBy = ["custRequestTypeId"]

[MSG]The String 'custRequestTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]productBacklogList = from("CustRequest").where(andExprs)...queryList()

[MSG]The String 'CustRequest' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]productBacklogList = from("CustRequest").where(andExprs)...queryList()

[MSG]The String 'custRequestTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString341

[SRC]taskBacklogList = from("CustRequestWorkEffort").where("c...queryList()

[MSG]The String 'CustRequestWorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString341

[SRC]taskBacklogList = from("CustRequestWorkEffort").where("c...queryList()

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator342

[SRC]int countImplTask=0, countImplTaskComplete=0, countInsta..ntTestTask=0

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator342

[SRC]int countImplTask=0, countImplTaskComplete=0, countInsta..ntTestTask=0

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator342

[SRC]int countImplTask=0, countImplTaskComplete=0, countInsta..ntTestTask=0

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator342

[SRC]int countImplTask=0, countImplTaskComplete=0, countInsta..ntTestTask=0

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator342

[SRC]int countImplTask=0, countImplTaskComplete=0, countInsta..ntTestTask=0

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator342

[SRC]int countImplTask=0, countImplTaskComplete=0, countInsta..ntTestTask=0

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator342

[SRC]int countImplTask=0, countImplTaskComplete=0, countInsta..ntTestTask=0

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator342

[SRC]int countImplTask=0, countImplTaskComplete=0, countInsta..ntTestTask=0

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator342

[SRC]int countImplTask=0, countImplTaskComplete=0, countInsta..ntTestTask=0

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator342

[SRC]int countImplTask=0, countImplTaskComplete=0, countInsta..ntTestTask=0

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator342

[SRC]int countImplTask=0, countImplTaskComplete=0, countInsta..ntTestTask=0

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator342

[SRC]int countImplTask=0, countImplTaskComplete=0, countInsta..ntTestTask=0

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator342

[SRC]int countImplTask=0, countImplTaskComplete=0, countInsta..ntTestTask=0

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator342

[SRC]int countImplTask=0, countImplTaskComplete=0, countInsta..ntTestTask=0

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

TrailingWhitespace345

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString346

[SRC]task = from("WorkEffort").where("workEffortId", taskId).queryOne()

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString346

[SRC]task = from("WorkEffort").where("workEffortId", taskId).queryOne()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

InvertedCondition347

[SRC]if ("SCRUM_TASK_IMPL" == task.workEffortTypeId) {

[MSG]SCRUM_TASK_IMPL is a constant expression on the left side of a compare equals operation

UnnecessaryGString347

[SRC]if ("SCRUM_TASK_IMPL" == task.workEffortTypeId) {

[MSG]The String 'SCRUM_TASK_IMPL' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator348

[SRC]countImplTask+=1

[MSG]The operator "+=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator348

[SRC]countImplTask+=1

[MSG]The operator "+=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

InvertedCondition349

[SRC]if ( "STS_COMPLETED" == task.currentStatusId || "STS_CAN..tStatusId) {

[MSG]STS_COMPLETED is a constant expression on the left side of a compare equals operation

InvertedCondition349

[SRC]if ( "STS_COMPLETED" == task.currentStatusId || "STS_CAN..tStatusId) {

[MSG]STS_CANCELLED is a constant expression on the left side of a compare equals operation

UnnecessaryGString349

[SRC]if ( "STS_COMPLETED" == task.currentStatusId || "STS_CAN..tStatusId) {

[MSG]The String 'STS_COMPLETED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]if ( "STS_COMPLETED" == task.currentStatusId || "STS_CAN..tStatusId) {

[MSG]The String 'STS_CANCELLED' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator350

[SRC]countImplTaskComplete+=1

[MSG]The operator "+=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator350

[SRC]countImplTaskComplete+=1

[MSG]The operator "+=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

InvertedCondition353

[SRC]else if ("SCRUM_TASK_INST" == task.workEffortTypeId) {

[MSG]SCRUM_TASK_INST is a constant expression on the left side of a compare equals operation

UnnecessaryGString353

[SRC]else if ("SCRUM_TASK_INST" == task.workEffortTypeId) {

[MSG]The String 'SCRUM_TASK_INST' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator354

[SRC]countInstallTask+=1

[MSG]The operator "+=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator354

[SRC]countInstallTask+=1

[MSG]The operator "+=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

InvertedCondition355

[SRC]if ( "STS_COMPLETED" == task.currentStatusId || "STS_CAN..tStatusId) {

[MSG]STS_COMPLETED is a constant expression on the left side of a compare equals operation

InvertedCondition355

[SRC]if ( "STS_COMPLETED" == task.currentStatusId || "STS_CAN..tStatusId) {

[MSG]STS_CANCELLED is a constant expression on the left side of a compare equals operation

UnnecessaryGString355

[SRC]if ( "STS_COMPLETED" == task.currentStatusId || "STS_CAN..tStatusId) {

[MSG]The String 'STS_COMPLETED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]if ( "STS_COMPLETED" == task.currentStatusId || "STS_CAN..tStatusId) {

[MSG]The String 'STS_CANCELLED' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator356

[SRC]countInstallTaskComplete+=1

[MSG]The operator "+=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator356

[SRC]countInstallTaskComplete+=1

[MSG]The operator "+=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

InvertedCondition359

[SRC]else if ("SCRUM_TASK_ERROR" == task.workEffortTypeId) {

[MSG]SCRUM_TASK_ERROR is a constant expression on the left side of a compare equals operation

UnnecessaryGString359

[SRC]else if ("SCRUM_TASK_ERROR" == task.workEffortTypeId) {

[MSG]The String 'SCRUM_TASK_ERROR' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator360

[SRC]countErrTask+=1

[MSG]The operator "+=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator360

[SRC]countErrTask+=1

[MSG]The operator "+=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

InvertedCondition361

[SRC]if ( "STS_COMPLETED" == task.currentStatusId || "STS_CAN..tStatusId) {

[MSG]STS_COMPLETED is a constant expression on the left side of a compare equals operation

InvertedCondition361

[SRC]if ( "STS_COMPLETED" == task.currentStatusId || "STS_CAN..tStatusId) {

[MSG]STS_CANCELLED is a constant expression on the left side of a compare equals operation

UnnecessaryGString361

[SRC]if ( "STS_COMPLETED" == task.currentStatusId || "STS_CAN..tStatusId) {

[MSG]The String 'STS_COMPLETED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]if ( "STS_COMPLETED" == task.currentStatusId || "STS_CAN..tStatusId) {

[MSG]The String 'STS_CANCELLED' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator362

[SRC]countErrTaskComplete+=1

[MSG]The operator "+=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator362

[SRC]countErrTaskComplete+=1

[MSG]The operator "+=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

InvertedCondition365

[SRC]else if ("SCRUM_TASK_TEST" == task.workEffortTypeId || "..tStatusId) {

[MSG]SCRUM_TASK_TEST is a constant expression on the left side of a compare equals operation

InvertedCondition365

[SRC]else if ("SCRUM_TASK_TEST" == task.workEffortTypeId || "..tStatusId) {

[MSG]STS_CANCELLED is a constant expression on the left side of a compare equals operation

UnnecessaryGString365

[SRC]else if ("SCRUM_TASK_TEST" == task.workEffortTypeId || "..tStatusId) {

[MSG]The String 'SCRUM_TASK_TEST' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]else if ("SCRUM_TASK_TEST" == task.workEffortTypeId || "..tStatusId) {

[MSG]The String 'STS_CANCELLED' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator366

[SRC]countTestTask+=1

[MSG]The operator "+=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator366

[SRC]countTestTask+=1

[MSG]The operator "+=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

TrailingWhitespace369

[SRC]if ((countImplTask > 0 || countErrTask > 0 || countInsta..TaskComplete

[MSG]Line ends with whitespace characters

UnnecessaryGString377

[SRC]backlogList = UtilMisc.sortMaps(backlogList, ["-custRequestName"])

[MSG]The String '-custRequestName' can be wrapped in single quotes instead of double quotes

➥ FindProductBacklogItem.groovy

Rule NamePriorityLine #Source Line / Message
UnusedVariable227

[SRC]def module = "FindProductBacklogItem.groovy"

[MSG]The variable [module] in class org.apache.ofbiz.scrum.None is not used

ExplicitCallToEqualsMethod237

[SRC]if ("Y".equals(parameters.noConditionFind)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to Y.equals(parameters.noConditionFind) method can be rewritten as (Y == (parameters.noConditionFind))

LineLength299

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The line exceeds 150 characters. The line is 231 characters.

ExplicitCallToEqualsMethod2133

[SRC]if ("N".equals(parameters.sequence)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to N.equals(parameters.sequence) method can be rewritten as (N == (parameters.sequence))

UnusedImport323

[SRC]import org.apache.ofbiz.base.util.UtilValidate

[MSG]The [org.apache.ofbiz.base.util.UtilValidate] import is never referenced

NoDef327

[SRC]def module = "FindProductBacklogItem.groovy"

[MSG]def for declaration should not be used

VariableTypeRequired327

[SRC]def module = "FindProductBacklogItem.groovy"

[MSG]The type is not specified for variable "module"

UnnecessaryGString327

[SRC]def module = "FindProductBacklogItem.groovy"

[MSG]The String 'FindProductBacklogItem.groovy' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]orderBy = "custRequestDate"

[MSG]The String 'custRequestDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]if ("Y".equals(parameters.noConditionFind)) {

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

SpaceAfterIf338

[SRC]if(parameters.productId){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace338

[SRC]if(parameters.productId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString339

[SRC]conditionBacklogList.add(EntityCondition.makeCondition("...productId))

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

TrailingWhitespace341

[SRC]

[MSG]Line ends with whitespace characters

SpaceAfterClosingBrace342

[SRC]if(parameters.custRequestTypeId){

[MSG]The closing brace for the block in class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAfterIf342

[SRC]if(parameters.custRequestTypeId){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace342

[SRC]if(parameters.custRequestTypeId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString343

[SRC]conditionBacklogList.add(EntityCondition.makeCondition("..uestTypeId))

[MSG]The String 'custRequestTypeId' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace344

[SRC]}else{

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString346

[SRC]orConditionBacklogList.add(EntityCondition.makeCondition..N_BACKLOG"))

[MSG]The String 'custRequestTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString346

[SRC]orConditionBacklogList.add(EntityCondition.makeCondition..N_BACKLOG"))

[MSG]The String 'RF_UNPLAN_BACKLOG' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]orConditionBacklogList.add(EntityCondition.makeCondition..D_BACKLOG"))

[MSG]The String 'custRequestTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]orConditionBacklogList.add(EntityCondition.makeCondition..D_BACKLOG"))

[MSG]The String 'RF_PROD_BACKLOG' can be wrapped in single quotes instead of double quotes

TrailingWhitespace350

[SRC]

[MSG]Line ends with whitespace characters

SpaceAfterClosingBrace351

[SRC]if(parameters.billed){

[MSG]The closing brace for the block in class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAfterIf351

[SRC]if(parameters.billed){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace351

[SRC]if(parameters.billed){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString352

[SRC]conditionBacklogList.add(EntityCondition.makeCondition("..ers.billed))

[MSG]The String 'billed' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace353

[SRC]}else{

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString355

[SRC]orConditionBacklogList.add(EntityCondition.makeCondition..QUALS, "Y"))

[MSG]The String 'billed' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]orConditionBacklogList.add(EntityCondition.makeCondition..QUALS, "Y"))

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]orConditionBacklogList.add(EntityCondition.makeCondition..QUALS, "N"))

[MSG]The String 'billed' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]orConditionBacklogList.add(EntityCondition.makeCondition..QUALS, "N"))

[MSG]The String 'N' can be wrapped in single quotes instead of double quotes

TrailingWhitespace359

[SRC]

[MSG]Line ends with whitespace characters

SpaceAfterIf360

[SRC]if(parameters.statusId){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace360

[SRC]if(parameters.statusId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString361

[SRC]orderBy = "custSequenceNum"

[MSG]The String 'custSequenceNum' can be wrapped in single quotes instead of double quotes

UnnecessaryGString362

[SRC]conditionBacklogList.add(EntityCondition.makeCondition("..s.statusId))

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

TrailingWhitespace364

[SRC]

[MSG]Line ends with whitespace characters

SpaceAfterIf365

[SRC]if(parameters.parentCustRequestId){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace365

[SRC]if(parameters.parentCustRequestId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString366

[SRC]conditionBacklogList.add(EntityCondition.makeCondition("..tRequestId))

[MSG]The String 'parentCustRequestId' can be wrapped in single quotes instead of double quotes

TrailingWhitespace368

[SRC]

[MSG]Line ends with whitespace characters

SpaceAfterIf369

[SRC]if(parameters.description){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace369

[SRC]if(parameters.description){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString370

[SRC]conditionBacklogList.add(EntityCondition.makeCondition("..tion + "%"))

[MSG]The String 'description' can be wrapped in single quotes instead of double quotes

UnnecessaryGString370

[SRC]conditionBacklogList.add(EntityCondition.makeCondition("..tion + "%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

UnnecessaryGString370

[SRC]conditionBacklogList.add(EntityCondition.makeCondition("..tion + "%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

TrailingWhitespace372

[SRC]

[MSG]Line ends with whitespace characters

SpaceAfterIf373

[SRC]if(parameters.fromPartyId){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace373

[SRC]if(parameters.fromPartyId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString374

[SRC]conditionBacklogList.add(EntityCondition.makeCondition("..tyId + "%"))

[MSG]The String 'fromPartyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString374

[SRC]conditionBacklogList.add(EntityCondition.makeCondition("..tyId + "%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

UnnecessaryGString374

[SRC]conditionBacklogList.add(EntityCondition.makeCondition("..tyId + "%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

TrailingWhitespace376

[SRC]

[MSG]Line ends with whitespace characters

SpaceBeforeOpeningBrace377

[SRC]if (parameters.custRequestDate){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString379

[SRC]fromDate = fromDate + " " + "00:00:00.000"

[MSG]The String ' ' can be wrapped in single quotes instead of double quotes

UnnecessaryGString379

[SRC]fromDate = fromDate + " " + "00:00:00.000"

[MSG]The String '00:00:00.000' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]conditionBacklogList.add(EntityCondition.makeCondition("..(fromDate)))

[MSG]The String 'custRequestDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString382

[SRC]thruDate = thruDate + " " + "23:59:59.999"

[MSG]The String ' ' can be wrapped in single quotes instead of double quotes

UnnecessaryGString382

[SRC]thruDate = thruDate + " " + "23:59:59.999"

[MSG]The String '23:59:59.999' can be wrapped in single quotes instead of double quotes

UnnecessaryGString383

[SRC]conditionBacklogList.add(EntityCondition.makeCondition("..(thruDate)))

[MSG]The String 'custRequestDate' can be wrapped in single quotes instead of double quotes

TrailingWhitespace385

[SRC]

[MSG]Line ends with whitespace characters

SpaceAfterIf386

[SRC]if(parameters.custRequestId){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace386

[SRC]if(parameters.custRequestId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString387

[SRC]conditionBacklogList.add(EntityCondition.makeCondition("..stId + "%"))

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString387

[SRC]conditionBacklogList.add(EntityCondition.makeCondition("..stId + "%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

TrailingWhitespace389

[SRC]

[MSG]Line ends with whitespace characters

TrailingWhitespace391

[SRC]

[MSG]Line ends with whitespace characters

SpaceAfterIf392

[SRC]if(orConditionsBacklog){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace392

[SRC]if(orConditionsBacklog){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

TrailingWhitespace395

[SRC]

[MSG]Line ends with whitespace characters

TrailingWhitespace397

[SRC]

[MSG]Line ends with whitespace characters

SpaceAfterComma399

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The parameter custRequestTypeId in the call to method select within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma399

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The parameter productId in the call to method select within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma399

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The parameter billed in the call to method select within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma399

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The parameter custRequestDate in the call to method select within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma399

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The parameter fromPartyId in the call to method select within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString399

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString399

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The String 'custRequestTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString399

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The String 'custSequenceNum' can be wrapped in single quotes instead of double quotes

UnnecessaryGString399

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString399

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The String 'description' can be wrapped in single quotes instead of double quotes

UnnecessaryGString399

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The String 'custEstimatedMilliSeconds' can be wrapped in single quotes instead of double quotes

UnnecessaryGString399

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The String 'custRequestName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString399

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The String 'parentCustRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString399

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString399

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The String 'billed' can be wrapped in single quotes instead of double quotes

UnnecessaryGString399

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The String 'custRequestDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString399

[SRC]backlogList = select("custRequestId","custRequestTypeId"..romPartyId")

[MSG]The String 'fromPartyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3100

[SRC].from("CustRequestAndCustRequestItem")

[MSG]The String 'CustRequestAndCustRequestItem' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3102

[SRC].orderBy("-custRequestTypeId", orderBy)

[MSG]The String '-custRequestTypeId' can be wrapped in single quotes instead of double quotes

TrailingWhitespace3104

[SRC]

[MSG]Line ends with whitespace characters

NoDef3105

[SRC]def countSequenceBacklog = 1

[MSG]def for declaration should not be used

VariableTypeRequired3105

[SRC]def countSequenceBacklog = 1

[MSG]The type is not specified for variable "countSequenceBacklog"

NoDef3106

[SRC]def backlogItems = []

[MSG]def for declaration should not be used

VariableTypeRequired3106

[SRC]def backlogItems = []

[MSG]The type is not specified for variable "backlogItems"

UnnecessaryParenthesesForMethodCallWithClosure3107

[SRC]backlogList.each() { backlogItem ->

[MSG]Violation in class org.apache.ofbiz.scrum.None. Parentheses in the 'each' method call are unnecessary and can be removed.

NoDef3108

[SRC]def tempBacklog = [:]

[MSG]def for declaration should not be used

VariableTypeRequired3108

[SRC]def tempBacklog = [:]

[MSG]The type is not specified for variable "tempBacklog"

UnnecessaryGString3113

[SRC]backlogCustWorkEffortList = from("CustRequestWorkEffort"...queryList()

[MSG]The String 'CustRequestWorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3113

[SRC]backlogCustWorkEffortList = from("CustRequestWorkEffort"...queryList()

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryParenthesesForMethodCallWithClosure3116

[SRC]backlogCustWorkEffortList.each() { custWorkEffortMap ->

[MSG]Violation in class org.apache.ofbiz.scrum.None. Parentheses in the 'each' method call are unnecessary and can be removed.

SpaceAfterComma3117

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The map entry partyId:null within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundMapEntryColon3117

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The colon for the literal Map entry for key [taskId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3117

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3117

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3117

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The String 'taskId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3117

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3117

[SRC]result = runService('getScrumActualHour', ["taskId" : cu.. userLogin])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

SpaceAfterIf3120

[SRC]if(actualHours) {

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

TrailingWhitespace3131

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString3133

[SRC]if ("N".equals(parameters.sequence)) {

[MSG]The String 'N' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3134

[SRC]backlogItems = UtilMisc.sortMaps(backlogItems, ["parentC..RequestId"])

[MSG]The String 'parentCustRequestId' can be wrapped in single quotes instead of double quotes

➥ FindTaskList.groovy

Rule NamePriorityLine #Source Line / Message
SpaceAroundOperator337

[SRC]resultList=[]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator337

[SRC]resultList=[]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator338

[SRC]taskList=[]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator338

[SRC]taskList=[]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator339

[SRC]implementTaskList=[]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator339

[SRC]implementTaskList=[]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator340

[SRC]testTaskList=[]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator340

[SRC]testTaskList=[]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator345

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId !=..ame != null)

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceBeforeOpeningBrace348

[SRC]||(viewIndexNo_1 > 0)||(viewIndexNo_2 > 0)||(viewIndexNo..xNo_4 > 0)){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator349

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId != null)){

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator349

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId != null)){

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator349

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId != null)){

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator349

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId != null)){

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceBeforeOpeningBrace349

[SRC]if ((taskId != null)||(taskName != null)||(taskTypeId != null)){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString352

[SRC]exprBldr.add(EntityCondition.makeCondition("workEffortId..LS, taskId))

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace354

[SRC]if (taskName){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator355

[SRC]exprBldr.add(EntityCondition.makeCondition("workEffortNa..skName+"%"))

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator355

[SRC]exprBldr.add(EntityCondition.makeCondition("workEffortNa..skName+"%"))

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator355

[SRC]exprBldr.add(EntityCondition.makeCondition("workEffortNa..skName+"%"))

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator355

[SRC]exprBldr.add(EntityCondition.makeCondition("workEffortNa..skName+"%"))

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

UnnecessaryGString355

[SRC]exprBldr.add(EntityCondition.makeCondition("workEffortNa..skName+"%"))

[MSG]The String 'workEffortName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]exprBldr.add(EntityCondition.makeCondition("workEffortNa..skName+"%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]exprBldr.add(EntityCondition.makeCondition("workEffortNa..skName+"%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace357

[SRC]if (taskTypeId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString358

[SRC]exprBldr.add(EntityCondition.makeCondition("workEffortTy..taskTypeId))

[MSG]The String 'workEffortTypeId' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace360

[SRC]if (statusId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString361

[SRC]exprBldr.add(EntityCondition.makeCondition("currentStatu.., statusId))

[MSG]The String 'currentStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]unplannedTaskList = from("UnPlannedBacklogsAndTasks").wh...queryList()

[MSG]The String 'UnPlannedBacklogsAndTasks' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]unplannedTaskList = from("UnPlannedBacklogsAndTasks").wh...queryList()

[MSG]The String '-createdDate' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace365

[SRC]else{

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString366

[SRC]unplannedTaskList = from("UnPlannedBacklogsAndTasks").or...queryList()

[MSG]The String 'UnPlannedBacklogsAndTasks' can be wrapped in single quotes instead of double quotes

UnnecessaryGString366

[SRC]unplannedTaskList = from("UnPlannedBacklogsAndTasks").or...queryList()

[MSG]The String '-createdDate' can be wrapped in single quotes instead of double quotes

TrailingWhitespace368

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString371

[SRC]exprBldr2.add(EntityCondition.makeCondition("taskId", En..LS, taskId))

[MSG]The String 'taskId' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace373

[SRC]if (taskName){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator374

[SRC]exprBldr2.add(EntityCondition.makeCondition("taskName", ..skName+"%"))

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator374

[SRC]exprBldr2.add(EntityCondition.makeCondition("taskName", ..skName+"%"))

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator374

[SRC]exprBldr2.add(EntityCondition.makeCondition("taskName", ..skName+"%"))

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator374

[SRC]exprBldr2.add(EntityCondition.makeCondition("taskName", ..skName+"%"))

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

UnnecessaryGString374

[SRC]exprBldr2.add(EntityCondition.makeCondition("taskName", ..skName+"%"))

[MSG]The String 'taskName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString374

[SRC]exprBldr2.add(EntityCondition.makeCondition("taskName", ..skName+"%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

UnnecessaryGString374

[SRC]exprBldr2.add(EntityCondition.makeCondition("taskName", ..skName+"%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace376

[SRC]if (taskTypeId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString377

[SRC]exprBldr2.add(EntityCondition.makeCondition("taskTypeId"..taskTypeId))

[MSG]The String 'taskTypeId' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace379

[SRC]if (statusId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString380

[SRC]exprBldr2.add(EntityCondition.makeCondition("taskCurrent.., statusId))

[MSG]The String 'taskCurrentStatusId' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace382

[SRC]if (sprintId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString383

[SRC]exprBldr2.add(EntityCondition.makeCondition("sprintId", .., sprintId))

[MSG]The String 'sprintId' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace385

[SRC]if (sprintName){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator386

[SRC]exprBldr2.add(EntityCondition.makeCondition("sprintName"..ntName+"%"))

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator386

[SRC]exprBldr2.add(EntityCondition.makeCondition("sprintName"..ntName+"%"))

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator386

[SRC]exprBldr2.add(EntityCondition.makeCondition("sprintName"..ntName+"%"))

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator386

[SRC]exprBldr2.add(EntityCondition.makeCondition("sprintName"..ntName+"%"))

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

UnnecessaryGString386

[SRC]exprBldr2.add(EntityCondition.makeCondition("sprintName"..ntName+"%"))

[MSG]The String 'sprintName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString386

[SRC]exprBldr2.add(EntityCondition.makeCondition("sprintName"..ntName+"%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

UnnecessaryGString386

[SRC]exprBldr2.add(EntityCondition.makeCondition("sprintName"..ntName+"%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace388

[SRC]if (projectId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString389

[SRC]exprBldr2.add(EntityCondition.makeCondition("projectId",.. projectId))

[MSG]The String 'projectId' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace391

[SRC]if (projectName){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator392

[SRC]exprBldr2.add(EntityCondition.makeCondition("projectName..ctName+"%"))

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator392

[SRC]exprBldr2.add(EntityCondition.makeCondition("projectName..ctName+"%"))

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator392

[SRC]exprBldr2.add(EntityCondition.makeCondition("projectName..ctName+"%"))

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator392

[SRC]exprBldr2.add(EntityCondition.makeCondition("projectName..ctName+"%"))

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

UnnecessaryGString392

[SRC]exprBldr2.add(EntityCondition.makeCondition("projectName..ctName+"%"))

[MSG]The String 'projectName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString392

[SRC]exprBldr2.add(EntityCondition.makeCondition("projectName..ctName+"%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

UnnecessaryGString392

[SRC]exprBldr2.add(EntityCondition.makeCondition("projectName..ctName+"%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

UnnecessaryGString394

[SRC]exprBldr2.add(EntityCondition.makeCondition("sprintTypeI..UM_SPRINT"))

[MSG]The String 'sprintTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString394

[SRC]exprBldr2.add(EntityCondition.makeCondition("sprintTypeI..UM_SPRINT"))

[MSG]The String 'SCRUM_SPRINT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString395

[SRC]plannedTaskList = from("ProjectSprintBacklogAndTask").wh...queryList()

[MSG]The String 'ProjectSprintBacklogAndTask' can be wrapped in single quotes instead of double quotes

UnnecessaryGString395

[SRC]plannedTaskList = from("ProjectSprintBacklogAndTask").wh...queryList()

[MSG]The String '-taskCreatedDate' can be wrapped in single quotes instead of double quotes

TrailingWhitespace396

[SRC]

[MSG]Line ends with whitespace characters

SpaceBeforeOpeningBrace397

[SRC]unplannedTaskList.each{ unplannedTaskMap ->

[MSG]The opening brace for the closure in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryObjectReferences3107

[SRC]unplannedMap.taskCreatedDate = unplannedTaskMap.createdDate

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3108

[SRC]unplannedMap.custRequestId = unplannedTaskMap.custRequestId

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3109

[SRC]unplannedMap.description = unplannedTaskMap.description

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3110

[SRC]unplannedMap.custRequestTypeId = unplannedTaskMap.custRequestTypeId

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3111

[SRC]unplannedMap.taskActualMilliSeconds = unplannedTaskMap.a..MilliSeconds

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3112

[SRC]unplannedMap.taskEstimatedStartDate = unplannedTaskMap.e..tedStartDate

[MSG]The code could be more concise by using a with() or identity() block

TrailingWhitespace3115

[SRC]

[MSG]Line ends with whitespace characters

SpaceBeforeOpeningBrace3116

[SRC]plannedTaskList.each{ plannedTaskMap ->

[MSG]The opening brace for the closure in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryObjectReferences3126

[SRC]plannedMap.projectId = plannedTaskMap.projectId

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3127

[SRC]plannedMap.projectName = plannedTaskMap.projectName

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3128

[SRC]plannedMap.custRequestId = plannedTaskMap.custRequestId

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3129

[SRC]plannedMap.description = plannedTaskMap.description

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3130

[SRC]plannedMap.custRequestTypeId = plannedTaskMap.custRequestTypeId

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3131

[SRC]plannedMap.taskActualMilliSeconds = plannedTaskMap.taskA..MilliSeconds

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences3132

[SRC]plannedMap.taskEstimatedStartDate = plannedTaskMap.taskE..tedStartDate

[MSG]The code could be more concise by using a with() or identity() block

SpaceBeforeOpeningBrace3136

[SRC]if (backlogTypeId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3137

[SRC]if (backlogTypeId=="Y"){

[MSG]The operator "==" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3137

[SRC]if (backlogTypeId=="Y"){

[MSG]The operator "==" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceBeforeOpeningBrace3137

[SRC]if (backlogTypeId=="Y"){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString3137

[SRC]if (backlogTypeId=="Y"){

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

SpaceAfterOpeningBrace3138

[SRC]taskList.each{taskMap ->

[MSG]The opening brace for the closure in class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceBeforeOpeningBrace3138

[SRC]taskList.each{taskMap ->

[MSG]The opening brace for the closure in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterIf3139

[SRC]if(taskMap.custRequestTypeId=="RF_UNPLAN_BACKLOG"){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceAroundOperator3139

[SRC]if(taskMap.custRequestTypeId=="RF_UNPLAN_BACKLOG"){

[MSG]The operator "==" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3139

[SRC]if(taskMap.custRequestTypeId=="RF_UNPLAN_BACKLOG"){

[MSG]The operator "==" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceBeforeOpeningBrace3139

[SRC]if(taskMap.custRequestTypeId=="RF_UNPLAN_BACKLOG"){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString3139

[SRC]if(taskMap.custRequestTypeId=="RF_UNPLAN_BACKLOG"){

[MSG]The String 'RF_UNPLAN_BACKLOG' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3144

[SRC]if (backlogTypeId=="N"){

[MSG]The operator "==" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3144

[SRC]if (backlogTypeId=="N"){

[MSG]The operator "==" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceBeforeOpeningBrace3144

[SRC]if (backlogTypeId=="N"){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString3144

[SRC]if (backlogTypeId=="N"){

[MSG]The String 'N' can be wrapped in single quotes instead of double quotes

SpaceAfterOpeningBrace3145

[SRC]taskList.each{taskMap ->

[MSG]The opening brace for the closure in class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceBeforeOpeningBrace3145

[SRC]taskList.each{taskMap ->

[MSG]The opening brace for the closure in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterIf3146

[SRC]if(taskMap.custRequestTypeId=="RF_PROD_BACKLOG"){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceAroundOperator3146

[SRC]if(taskMap.custRequestTypeId=="RF_PROD_BACKLOG"){

[MSG]The operator "==" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3146

[SRC]if(taskMap.custRequestTypeId=="RF_PROD_BACKLOG"){

[MSG]The operator "==" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceBeforeOpeningBrace3146

[SRC]if(taskMap.custRequestTypeId=="RF_PROD_BACKLOG"){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString3146

[SRC]if(taskMap.custRequestTypeId=="RF_PROD_BACKLOG"){

[MSG]The String 'RF_PROD_BACKLOG' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace3157

[SRC]if (partyId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString3162

[SRC]assignToList = from("WorkEffortPartyAssignment").where("...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3162

[SRC]assignToList = from("WorkEffortPartyAssignment").where("...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3162

[SRC]assignToList = from("WorkEffortPartyAssignment").where("...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3173

[SRC]assignToList = from("WorkEffortPartyAssignment").where("...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3173

[SRC]assignToList = from("WorkEffortPartyAssignment").where("...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

TrailingWhitespace3182

[SRC]

[MSG]Line ends with whitespace characters

SpaceAfterOpeningBrace3183

[SRC]resultList.each{resultMap ->

[MSG]The opening brace for the closure in class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceBeforeOpeningBrace3183

[SRC]resultList.each{resultMap ->

[MSG]The opening brace for the closure in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

CouldBeSwitchStatement3184

[SRC]if (resultMap.taskTypeId=="SCRUM_TASK_IMPL"){

[MSG]Code could use switch statement

SpaceAroundOperator3184

[SRC]if (resultMap.taskTypeId=="SCRUM_TASK_IMPL"){

[MSG]The operator "==" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3184

[SRC]if (resultMap.taskTypeId=="SCRUM_TASK_IMPL"){

[MSG]The operator "==" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceBeforeOpeningBrace3184

[SRC]if (resultMap.taskTypeId=="SCRUM_TASK_IMPL"){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString3184

[SRC]if (resultMap.taskTypeId=="SCRUM_TASK_IMPL"){

[MSG]The String 'SCRUM_TASK_IMPL' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3187

[SRC]if (resultMap.taskTypeId=="SCRUM_TASK_INST"){

[MSG]The operator "==" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3187

[SRC]if (resultMap.taskTypeId=="SCRUM_TASK_INST"){

[MSG]The operator "==" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceBeforeOpeningBrace3187

[SRC]if (resultMap.taskTypeId=="SCRUM_TASK_INST"){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString3187

[SRC]if (resultMap.taskTypeId=="SCRUM_TASK_INST"){

[MSG]The String 'SCRUM_TASK_INST' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3190

[SRC]if (resultMap.taskTypeId=="SCRUM_TASK_TEST"){

[MSG]The operator "==" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3190

[SRC]if (resultMap.taskTypeId=="SCRUM_TASK_TEST"){

[MSG]The operator "==" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceBeforeOpeningBrace3190

[SRC]if (resultMap.taskTypeId=="SCRUM_TASK_TEST"){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString3190

[SRC]if (resultMap.taskTypeId=="SCRUM_TASK_TEST"){

[MSG]The String 'SCRUM_TASK_TEST' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator3193

[SRC]if (resultMap.taskTypeId=="SCRUM_TASK_ERROR"){

[MSG]The operator "==" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator3193

[SRC]if (resultMap.taskTypeId=="SCRUM_TASK_ERROR"){

[MSG]The operator "==" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceBeforeOpeningBrace3193

[SRC]if (resultMap.taskTypeId=="SCRUM_TASK_ERROR"){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString3193

[SRC]if (resultMap.taskTypeId=="SCRUM_TASK_ERROR"){

[MSG]The String 'SCRUM_TASK_ERROR' can be wrapped in single quotes instead of double quotes

TrailingWhitespace3197

[SRC]

[MSG]Line ends with whitespace characters

SpaceBeforeOpeningBrace3198

[SRC]if (implementTaskList){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceBeforeOpeningBrace3201

[SRC]if (installTaskList){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceBeforeOpeningBrace3204

[SRC]if (testTaskList){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceBeforeOpeningBrace3207

[SRC]if (errorTaskList){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

➥ ListCurrentProducts.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod232

[SRC]if ("Any".equals(statusId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to Any.equals(statusId) method can be rewritten as (Any == (statusId))

ExplicitCallToEqualsMethod254

[SRC]if ("PRODUCT_ACTIVE".equals(statusId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to PRODUCT_ACTIVE.equals(statusId) method can be rewritten as (PRODUCT_ACTIVE == (statusId))

ExplicitCallToEqualsMethod288

[SRC]if ("SCRUM_PRODUCT_OWNER".equals(groupId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to SCRUM_PRODUCT_OWNER.equals(groupId) method can be rewritten as (SCRUM_PRODUCT_OWNER == (groupId))

LineLength289

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]The line exceeds 150 characters. The line is 158 characters.

ExplicitCallToEqualsMethod293

[SRC]if (productIdInner.equals(product.productId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to productIdInner.equals(product.productId) method can be rewritten as (productIdInner == (product.productId))

ExplicitCallToEqualsMethod298

[SRC]} else if ("SCRUM_STAKEHOLDER".equals(groupId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to SCRUM_STAKEHOLDER.equals(groupId) method can be rewritten as (SCRUM_STAKEHOLDER == (groupId))

LineLength2107

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The line exceeds 150 characters. The line is 187 characters.

ExplicitCallToEqualsMethod2111

[SRC]if (stakeholderProduct.equals(product.productId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to stakeholderProduct.equals(product.productId) method can be rewritten as (stakeholderProduct == (product.productId))

LineLength2118

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The line exceeds 150 characters. The line is 235 characters.

ExplicitCallToEqualsMethod2123

[SRC]} else if ("SCRUM_MASTER".equals(groupId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to SCRUM_MASTER.equals(groupId) method can be rewritten as (SCRUM_MASTER == (groupId))

LineLength2126

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The line exceeds 150 characters. The line is 229 characters.

LineLength2133

[SRC]projects = from("WorkEffortAndProduct").where("productId...queryList()

[MSG]The line exceeds 150 characters. The line is 183 characters.

LineLength2136

[SRC]projectPartyAssignment = from("WorkEffortPartyAssignment...queryList()

[MSG]The line exceeds 150 characters. The line is 176 characters.

LineLength2147

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The line exceeds 150 characters. The line is 160 characters.

ParameterName2148

[SRC]allSprintList.each { SprintListMap ->

[MSG]The parameter named SprintListMap in method <closure> of class org.apache.ofbiz.scrum.None does not match [a-z][a-zA-Z0-9]*

LineLength2150

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The line exceeds 150 characters. The line is 167 characters.

LineLength2159

[SRC]projects = from("WorkEffortAndProduct").where("productId...queryList()

[MSG]The line exceeds 150 characters. The line is 179 characters.

LineLength2163

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The line exceeds 150 characters. The line is 160 characters.

ParameterName2164

[SRC]allSprintList.each { SprintListMap ->

[MSG]The parameter named SprintListMap in method <closure> of class org.apache.ofbiz.scrum.None does not match [a-z][a-zA-Z0-9]*

LineLength2166

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The line exceeds 150 characters. The line is 167 characters.

LineLength2184

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The line exceeds 150 characters. The line is 171 characters.

IfStatementBraces2198

[SRC]if(addAllProducts)

[MSG]The if statement lacks braces

UnusedImport324

[SRC]import org.apache.ofbiz.base.util.UtilValidate

[MSG]The [org.apache.ofbiz.base.util.UtilValidate] import is never referenced

UnnecessaryGString332

[SRC]if ("Any".equals(statusId)) {

[MSG]The String 'Any' can be wrapped in single quotes instead of double quotes

SpaceAfterIf337

[SRC]if(!security.hasEntityPermission("SCRUM", "_ADMIN", session)){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace337

[SRC]if(!security.hasEntityPermission("SCRUM", "_ADMIN", session)){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString337

[SRC]if(!security.hasEntityPermission("SCRUM", "_ADMIN", session)){

[MSG]The String 'SCRUM' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]if(!security.hasEntityPermission("SCRUM", "_ADMIN", session)){

[MSG]The String '_ADMIN' can be wrapped in single quotes instead of double quotes

SpaceAfterIf338

[SRC]if(security.hasEntityPermission("SCRUM_PRODUCT", "_ADMIN", session)){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace338

[SRC]if(security.hasEntityPermission("SCRUM_PRODUCT", "_ADMIN", session)){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString338

[SRC]if(security.hasEntityPermission("SCRUM_PRODUCT", "_ADMIN", session)){

[MSG]The String 'SCRUM_PRODUCT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]if(security.hasEntityPermission("SCRUM_PRODUCT", "_ADMIN", session)){

[MSG]The String '_ADMIN' can be wrapped in single quotes instead of double quotes

UnnecessaryGString339

[SRC]roleTypeId = "PRODUCT_OWNER"

[MSG]The String 'PRODUCT_OWNER' can be wrapped in single quotes instead of double quotes

SpaceAfterIf344

[SRC]if(partyId){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace344

[SRC]if(partyId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString345

[SRC]paramCond.add(EntityCondition.makeCondition("partyId", E..S, partyId))

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

SpaceAfterIf347

[SRC]if(productId){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace347

[SRC]if(productId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString348

[SRC]paramCond.add(EntityCondition.makeCondition("productId",..ctId + "%"))

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString348

[SRC]paramCond.add(EntityCondition.makeCondition("productId",..ctId + "%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

SpaceAfterIf350

[SRC]if(internalName){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace350

[SRC]if(internalName){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString351

[SRC]paramCond.add(EntityCondition.makeCondition("internalNam..Name + "%"))

[MSG]The String 'internalName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString351

[SRC]paramCond.add(EntityCondition.makeCondition("internalNam..Name + "%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

UnnecessaryGString351

[SRC]paramCond.add(EntityCondition.makeCondition("internalNam..Name + "%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

SpaceAfterIf353

[SRC]if(statusId){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace353

[SRC]if(statusId){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString354

[SRC]if ("PRODUCT_ACTIVE".equals(statusId)) {

[MSG]The String 'PRODUCT_ACTIVE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]paramCond.add(EntityCondition.makeCondition("supportDisc..UALS, null))

[MSG]The String 'supportDiscontinuationDate' can be wrapped in single quotes instead of double quotes

Indentation357

[SRC]paramCond.add(EntityCondition.makeCondition("supportDisc..QUAL, null))

[MSG]The statement on line 57 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 14

UnnecessaryGString357

[SRC]paramCond.add(EntityCondition.makeCondition("supportDisc..QUAL, null))

[MSG]The String 'supportDiscontinuationDate' can be wrapped in single quotes instead of double quotes

TrailingWhitespace360

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString361

[SRC]paramCond.add(EntityCondition.makeCondition("productType..CRUM_ITEM"))

[MSG]The String 'productTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]paramCond.add(EntityCondition.makeCondition("productType..CRUM_ITEM"))

[MSG]The String 'SCRUM_ITEM' can be wrapped in single quotes instead of double quotes

UnnecessaryGString362

[SRC]paramCond.add(EntityCondition.makeCondition("roleTypeId"..WNER_COMP"))

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString362

[SRC]paramCond.add(EntityCondition.makeCondition("roleTypeId"..WNER_COMP"))

[MSG]The String 'PRODUCT_OWNER_COMP' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]paramCond.add(EntityCondition.makeCondition("thruDate", ..UALS, null))

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

TrailingWhitespace364

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString365

[SRC]allProducts = from("ProductAndRole").where(paramCond).or...queryList()

[MSG]The String 'ProductAndRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]allProducts = from("ProductAndRole").where(paramCond).or...queryList()

[MSG]The String 'groupName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]allProducts = from("ProductAndRole").where(paramCond).or...queryList()

[MSG]The String 'internalName' can be wrapped in single quotes instead of double quotes

TrailingWhitespace366

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString367

[SRC]partyAndSecurityGroupList = select("partyId", "groupId")

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString367

[SRC]partyAndSecurityGroupList = select("partyId", "groupId")

[MSG]The String 'groupId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC].from("ScrumMemberUserLoginAndSecurityGroup").where(Enti..eCondition([

[MSG]The String 'ScrumMemberUserLoginAndSecurityGroup' can be wrapped in single quotes instead of double quotes

UnnecessaryGString369

[SRC]EntityCondition.makeCondition ("partyId", EntityOperator..in.partyId),

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString370

[SRC]EntityCondition.makeCondition ("partyStatusId", EntityOp.._DISABLED"),

[MSG]The String 'partyStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString370

[SRC]EntityCondition.makeCondition ("partyStatusId", EntityOp.._DISABLED"),

[MSG]The String 'PARTY_DISABLED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString371

[SRC]EntityCondition.makeCondition ("thruDate", EntityOperato..QUALS, null)

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString373

[SRC].orderBy("partyId")

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

TrailingWhitespace375

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString380

[SRC]productMap = from("Product").where("productId", product...).queryOne()

[MSG]The String 'Product' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]productMap = from("Product").where("productId", product...).queryOne()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

SpaceAfterComma381

[SRC]product.put("longDescription",productMap.longDescription)

[MSG]The parameter productMap.longDescription in the call to method put within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString381

[SRC]product.put("longDescription",productMap.longDescription)

[MSG]The String 'longDescription' can be wrapped in single quotes instead of double quotes

SpaceAfterClosingBrace382

[SRC]if(security.hasEntityPermission("SCRUM", "_ADMIN", session)){

[MSG]The closing brace for the block in class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAfterIf382

[SRC]if(security.hasEntityPermission("SCRUM", "_ADMIN", session)){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace382

[SRC]if(security.hasEntityPermission("SCRUM", "_ADMIN", session)){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString382

[SRC]if(security.hasEntityPermission("SCRUM", "_ADMIN", session)){

[MSG]The String 'SCRUM' can be wrapped in single quotes instead of double quotes

UnnecessaryGString382

[SRC]if(security.hasEntityPermission("SCRUM", "_ADMIN", session)){

[MSG]The String '_ADMIN' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace384

[SRC]}else{

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString388

[SRC]if ("SCRUM_PRODUCT_OWNER".equals(groupId)) {

[MSG]The String 'SCRUM_PRODUCT_OWNER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString389

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]The String 'ProductRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString389

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString389

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString389

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString398

[SRC]} else if ("SCRUM_STAKEHOLDER".equals(groupId)) {

[MSG]The String 'SCRUM_STAKEHOLDER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3101

[SRC]EntityCondition.makeCondition ("partyId", EntityOperator..in.partyId),

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3102

[SRC]EntityCondition.makeCondition ("roleTypeId", EntityOpera..AKEHOLDER"),

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3102

[SRC]EntityCondition.makeCondition ("roleTypeId", EntityOpera..AKEHOLDER"),

[MSG]The String 'STAKEHOLDER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3103

[SRC]EntityCondition.makeCondition ("partyStatusId", EntityOp.._DISABLED"),

[MSG]The String 'partyStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3103

[SRC]EntityCondition.makeCondition ("partyStatusId", EntityOp.._DISABLED"),

[MSG]The String 'PARTY_DISABLED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3104

[SRC]EntityCondition.makeCondition ("thruDate", EntityOperato..QUALS, null)

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3106

[SRC]scrumRolesPersonAndCompanyList = from("ScrumRolesPersonA...queryList()

[MSG]The String 'ScrumRolesPersonAndCompany' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3107

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The String 'ProductRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3107

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3107

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3107

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The String 'PRODUCT_OWNER_COMP' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3107

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon3118

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The colon for the literal Map entry for key [productId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3118

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3118

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The colon for the literal Map entry for key [roleTypeId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3118

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The colon for the literal Map entry for key [supportDiscontinuationDate] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3118

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The colon for the literal Map entry for key [thruDate] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3118

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The String 'ProductAndRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3118

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3118

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3118

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3118

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The String 'STAKEHOLDER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3118

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The String 'supportDiscontinuationDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3118

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3123

[SRC]} else if ("SCRUM_MASTER".equals(groupId)) {

[MSG]The String 'SCRUM_MASTER' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon3126

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The colon for the literal Map entry for key [productId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3126

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3126

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The colon for the literal Map entry for key [roleTypeId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3126

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The colon for the literal Map entry for key [supportDiscontinuationDate] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3126

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The colon for the literal Map entry for key [thruDate] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3126

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The String 'ProductAndRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3126

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3126

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3126

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3126

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The String 'SCRUM_MASTER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3126

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The String 'supportDiscontinuationDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3126

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3133

[SRC]projects = from("WorkEffortAndProduct").where("productId...queryList()

[MSG]The String 'WorkEffortAndProduct' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3133

[SRC]projects = from("WorkEffortAndProduct").where("productId...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3133

[SRC]projects = from("WorkEffortAndProduct").where("productId...queryList()

[MSG]The String 'workEffortTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3133

[SRC]projects = from("WorkEffortAndProduct").where("productId...queryList()

[MSG]The String 'SCRUM_PROJECT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3133

[SRC]projects = from("WorkEffortAndProduct").where("productId...queryList()

[MSG]The String 'currentStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3133

[SRC]projects = from("WorkEffortAndProduct").where("productId...queryList()

[MSG]The String 'SPJ_ACTIVE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3136

[SRC]projectPartyAssignment = from("WorkEffortPartyAssignment...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3136

[SRC]projectPartyAssignment = from("WorkEffortPartyAssignment...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3136

[SRC]projectPartyAssignment = from("WorkEffortPartyAssignment...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3147

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3147

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The String 'workEffortParentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3147

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The String 'currentStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3147

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The String 'SPRINT_ACTIVE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3150

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3150

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3150

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3159

[SRC]projects = from("WorkEffortAndProduct").where("productId...queryList()

[MSG]The String 'WorkEffortAndProduct' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3159

[SRC]projects = from("WorkEffortAndProduct").where("productId...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3159

[SRC]projects = from("WorkEffortAndProduct").where("productId...queryList()

[MSG]The String 'workEffortTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3159

[SRC]projects = from("WorkEffortAndProduct").where("productId...queryList()

[MSG]The String 'SCRUM_PROJECT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3159

[SRC]projects = from("WorkEffortAndProduct").where("productId...queryList()

[MSG]The String 'currentStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3159

[SRC]projects = from("WorkEffortAndProduct").where("productId...queryList()

[MSG]The String 'SPJ_ACTIVE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3163

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3163

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The String 'workEffortParentId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3163

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The String 'currentStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3163

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The String 'SPRINT_ACTIVE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3166

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3166

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3166

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3174

[SRC]exprBldr = [EntityCondition.makeCondition("statusId", En.._REVIEWED"),

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3174

[SRC]exprBldr = [EntityCondition.makeCondition("statusId", En.._REVIEWED"),

[MSG]The String 'CRQ_REVIEWED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3175

[SRC]EntityCondition.makeCondition("statusId", EntityOperator.._REOPENED")]

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3175

[SRC]EntityCondition.makeCondition("statusId", EntityOperator.._REOPENED")]

[MSG]The String 'CRQ_REOPENED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3176

[SRC]andExprs = [EntityCondition.makeCondition("productId", E...productId),

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3177

[SRC]EntityCondition.makeCondition("currentStatusId", EntityO..S_CREATED"),

[MSG]The String 'currentStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3177

[SRC]EntityCondition.makeCondition("currentStatusId", EntityO..S_CREATED"),

[MSG]The String 'STS_CREATED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3180

[SRC]unplannedBacklogList = from("UnPlannedBacklogsAndTasks")...queryList()

[MSG]The String 'UnPlannedBacklogsAndTasks' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3184

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3184

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3184

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

TrailingWhitespace3192

[SRC]

[MSG]Line ends with whitespace characters

Indentation3194

[SRC]products.add(product)

[MSG]The statement on line 194 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 23

SpaceAfterIf3198

[SRC]if(addAllProducts)

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

UnnecessaryGString3202

[SRC]logError("Party ID missing =========>>> : null ")

[MSG]The String 'Party ID missing =========>>> : null ' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace3205

[SRC]if (products){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

➥ ListCurrentSprints.groovy

Rule NamePriorityLine #Source Line / Message
LineLength238

[SRC]partyAndSecurityGroupList = select("partyId", "groupId")...queryList()

[MSG]The line exceeds 150 characters. The line is 157 characters.

IfStatementBraces257

[SRC]if (product != null) productName = product.internalName

[MSG]The if statement lacks braces

ExplicitCallToEqualsMethod266

[SRC]if ("SCRUM_PRODUCT_OWNER".equals(groupId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to SCRUM_PRODUCT_OWNER.equals(groupId) method can be rewritten as (SCRUM_PRODUCT_OWNER == (groupId))

LineLength267

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]The line exceeds 150 characters. The line is 177 characters.

ExplicitCallToGetAtMethod267

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to partyAndSecurityGroupList.getAt(0) method can be rewritten as partyAndSecurityGroupList[(0)]

ExplicitCallToEqualsMethod271

[SRC]}else if("SCRUM_STAKEHOLDER".equals(groupId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to SCRUM_STAKEHOLDER.equals(groupId) method can be rewritten as (SCRUM_STAKEHOLDER == (groupId))

LineLength280

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The line exceeds 150 characters. The line is 182 characters.

ExplicitCallToEqualsMethod284

[SRC]if (stakeholderProduct.equals(sprint.productId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to stakeholderProduct.equals(sprint.productId) method can be rewritten as (stakeholderProduct == (sprint.productId))

ExplicitCallToEqualsMethod299

[SRC]} else if("SCRUM_MASTER".equals(groupId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to SCRUM_MASTER.equals(groupId) method can be rewritten as (SCRUM_MASTER == (groupId))

LineLength2112

[SRC]projectPartyAssignment = from("WorkEffortPartyAssignment...queryList()

[MSG]The line exceeds 150 characters. The line is 159 characters.

ParameterName2121

[SRC]allSprintList.each { SprintListMap ->

[MSG]The parameter named SprintListMap in method <closure> of class org.apache.ofbiz.scrum.None does not match [a-z][a-zA-Z0-9]*

LineLength2123

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The line exceeds 150 characters. The line is 158 characters.

ParameterName2132

[SRC]allSprintList.each { SprintListMap ->

[MSG]The parameter named SprintListMap in method <closure> of class org.apache.ofbiz.scrum.None does not match [a-z][a-zA-Z0-9]*

LineLength2134

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The line exceeds 150 characters. The line is 154 characters.

LineLength2143

[SRC]|| security.hasEntityPermission("SCRUM_PROJECT", "_ROLE_..W", session)

[MSG]The line exceeds 150 characters. The line is 153 characters.

ExplicitCallToEqualsMethod2153

[SRC]if ("SCRUM_PRODUCT_OWNER".equals(groupId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to SCRUM_PRODUCT_OWNER.equals(groupId) method can be rewritten as (SCRUM_PRODUCT_OWNER == (groupId))

LineLength2154

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]The line exceeds 150 characters. The line is 181 characters.

ExplicitCallToGetAtMethod2154

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to partyAndSecurityGroupList.getAt(0) method can be rewritten as partyAndSecurityGroupList[(0)]

ExplicitCallToEqualsMethod2158

[SRC]}else if("SCRUM_STAKEHOLDER".equals(groupId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to SCRUM_STAKEHOLDER.equals(groupId) method can be rewritten as (SCRUM_STAKEHOLDER == (groupId))

LineLength2167

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The line exceeds 150 characters. The line is 190 characters.

ExplicitCallToEqualsMethod2171

[SRC]if (stakeholderProduct.equals(sprint.productId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to stakeholderProduct.equals(sprint.productId) method can be rewritten as (stakeholderProduct == (sprint.productId))

LineLength2178

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The line exceeds 150 characters. The line is 237 characters.

ExplicitCallToEqualsMethod2183

[SRC]} else if("SCRUM_MASTER".equals(groupId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to SCRUM_MASTER.equals(groupId) method can be rewritten as (SCRUM_MASTER == (groupId))

LineLength2186

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The line exceeds 150 characters. The line is 231 characters.

LineLength2192

[SRC]projectPartyAssignment = from("WorkEffortPartyAssignment...queryList()

[MSG]The line exceeds 150 characters. The line is 167 characters.

ParameterName2201

[SRC]allSprintList.each { SprintListMap ->

[MSG]The parameter named SprintListMap in method <closure> of class org.apache.ofbiz.scrum.None does not match [a-z][a-zA-Z0-9]*

LineLength2203

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The line exceeds 150 characters. The line is 166 characters.

ParameterName2212

[SRC]allSprintList.each { SprintListMap ->

[MSG]The parameter named SprintListMap in method <closure> of class org.apache.ofbiz.scrum.None does not match [a-z][a-zA-Z0-9]*

LineLength2214

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The line exceeds 150 characters. The line is 158 characters.

LineLength2223

[SRC]|| security.hasEntityPermission("SCRUM_PROJECT", "_ROLE_..W", session)

[MSG]The line exceeds 150 characters. The line is 157 characters.

UnnecessaryGString327

[SRC]EntityCondition.makeCondition ("projectTypeId", EntityOp..M_PROJECT"),

[MSG]The String 'projectTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString327

[SRC]EntityCondition.makeCondition ("projectTypeId", EntityOp..M_PROJECT"),

[MSG]The String 'SCRUM_PROJECT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]EntityCondition.makeCondition ("projectStatusId", Entity..SPJ_CLOSED")

[MSG]The String 'projectStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]EntityCondition.makeCondition ("projectStatusId", Entity..SPJ_CLOSED")

[MSG]The String 'SPJ_CLOSED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString331

[SRC]EntityCondition.makeCondition ("partyId", EntityOperator..in.partyId),

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]EntityCondition.makeCondition ("partyStatusId", EntityOp.._DISABLED"),

[MSG]The String 'partyStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]EntityCondition.makeCondition ("partyStatusId", EntityOp.._DISABLED"),

[MSG]The String 'PARTY_DISABLED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]EntityCondition.makeCondition ("thruDate", EntityOperato..QUALS, null)

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]fields = new HashSet(["partyId", "groupId"])

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]fields = new HashSet(["partyId", "groupId"])

[MSG]The String 'groupId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]allSprints = from("ProjectSprint").where(cond).orderBy("...queryList()

[MSG]The String 'ProjectSprint' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]allSprints = from("ProjectSprint").where(cond).orderBy("...queryList()

[MSG]The String 'projectName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]allSprints = from("ProjectSprint").where(cond).orderBy("...queryList()

[MSG]The String '-sprintActualStartDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]partyAndSecurityGroupList = select("partyId", "groupId")...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]partyAndSecurityGroupList = select("partyId", "groupId")...queryList()

[MSG]The String 'groupId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]partyAndSecurityGroupList = select("partyId", "groupId")...queryList()

[MSG]The String 'ScrumMemberUserLoginAndSecurityGroup' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]partyAndSecurityGroupList = select("partyId", "groupId")...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString345

[SRC]productAndRole = from("ProductAndRole").where("roleTypeI...queryList()

[MSG]The String 'ProductAndRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString345

[SRC]productAndRole = from("ProductAndRole").where("roleTypeI...queryList()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString345

[SRC]productAndRole = from("ProductAndRole").where("roleTypeI...queryList()

[MSG]The String 'PRODUCT_OWNER_COMP' can be wrapped in single quotes instead of double quotes

UnnecessaryGString345

[SRC]productAndRole = from("ProductAndRole").where("roleTypeI...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString346

[SRC]companyId = ""

[MSG]The String '' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]companyName = ""

[MSG]The String '' can be wrapped in single quotes instead of double quotes

NoTabCharacter349

[MSG]The tab character is not allowed in source files

Indentation349

[SRC]companyName = productAndRole.get(0).groupName

[MSG]The statement on line 49 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [9, 13, 17] but was 6

Indentation350

[SRC]companyId = productAndRole.get(0).partyId

[MSG]The statement on line 50 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [9, 13, 17] but was 6

UnnecessaryGString353

[SRC]sprint.put("companyId", companyId)

[MSG]The String 'companyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString354

[SRC]sprint.put("companyName", companyName)

[MSG]The String 'companyName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]product = from("Product").where("productId", sprint.prod..).queryOne()

[MSG]The String 'Product' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]product = from("Product").where("productId", sprint.prod..).queryOne()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]productName = ""

[MSG]The String '' can be wrapped in single quotes instead of double quotes

UnnecessaryGString358

[SRC]sprint.put("productName", productName)

[MSG]The String 'productName' can be wrapped in single quotes instead of double quotes

Indentation361

[SRC]oldProjectId = newProjectId

[MSG]The statement on line 61 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [9, 13, 17] but was 6

Indentation362

[SRC]countSprint = 0

[MSG]The statement on line 62 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [9, 13, 17] but was 6

Indentation364

[SRC]if (partyAndSecurityGroupList) {

[MSG]The statement on line 64 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [9, 13, 17] but was 8

Indentation365

[SRC]groupId = partyAndSecurityGroupList[0].groupId

[MSG]The statement on line 65 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [13, 17, 21] but was 12

Indentation366

[SRC]if ("SCRUM_PRODUCT_OWNER".equals(groupId)) {

[MSG]The statement on line 66 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [13, 17, 21] but was 12

SpaceAfterClosingBrace366

[SRC]if ("SCRUM_PRODUCT_OWNER".equals(groupId)) {

[MSG]The closing brace for the block in class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

UnnecessaryGString366

[SRC]if ("SCRUM_PRODUCT_OWNER".equals(groupId)) {

[MSG]The String 'SCRUM_PRODUCT_OWNER' can be wrapped in single quotes instead of double quotes

Indentation367

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]The statement on line 67 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

UnnecessaryGString367

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]The String 'ProductRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString367

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString367

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString367

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

Indentation368

[SRC]if (productAndRoleList) {

[MSG]The statement on line 68 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

Indentation369

[SRC]ismember = true

[MSG]The statement on line 69 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

SpaceAfterIf371

[SRC]}else if("SCRUM_STAKEHOLDER".equals(groupId)) {

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

UnnecessaryGString371

[SRC]}else if("SCRUM_STAKEHOLDER".equals(groupId)) {

[MSG]The String 'SCRUM_STAKEHOLDER' can be wrapped in single quotes instead of double quotes

Indentation373

[SRC]scrumRolesCond = EntityCondition.makeCondition([

[MSG]The statement on line 73 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

UnnecessaryGString374

[SRC]EntityCondition.makeCondition ("partyId", EntityOperator..in.partyId),

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString375

[SRC]EntityCondition.makeCondition ("roleTypeId", EntityOpera..AKEHOLDER"),

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString375

[SRC]EntityCondition.makeCondition ("roleTypeId", EntityOpera..AKEHOLDER"),

[MSG]The String 'STAKEHOLDER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString376

[SRC]EntityCondition.makeCondition ("partyStatusId", EntityOp.._DISABLED"),

[MSG]The String 'partyStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString376

[SRC]EntityCondition.makeCondition ("partyStatusId", EntityOp.._DISABLED"),

[MSG]The String 'PARTY_DISABLED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString377

[SRC]EntityCondition.makeCondition ("thruDate", EntityOperato..QUALS, null)

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

Indentation379

[SRC]scrumRolesPersonAndCompanyList = from("ScrumRolesPersonA...queryList()

[MSG]The statement on line 79 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

UnnecessaryGString379

[SRC]scrumRolesPersonAndCompanyList = from("ScrumRolesPersonA...queryList()

[MSG]The String 'ScrumRolesPersonAndCompany' can be wrapped in single quotes instead of double quotes

Indentation380

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The statement on line 80 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

UnnecessaryGString380

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The String 'ProductRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The String 'PRODUCT_OWNER_COMP' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

Indentation381

[SRC]if (productRoleList) {

[MSG]The statement on line 81 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

Indentation382

[SRC]productRoleList.each { productRoleMap ->

[MSG]The statement on line 82 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

Indentation383

[SRC]stakeholderProduct = productRoleMap.productId

[MSG]The statement on line 83 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [25, 29, 33] or one of [39, 43, 47] columns, but was 24

Indentation384

[SRC]if (stakeholderProduct.equals(sprint.productId)) {

[MSG]The statement on line 84 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [25, 29, 33] or one of [39, 43, 47] columns, but was 24

Indentation385

[SRC]ismember = true

[MSG]The statement on line 85 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [29, 33, 37] but was 28

Indentation390

[SRC]if (ismember == false) {

[MSG]The statement on line 90 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

Indentation391

[SRC]productAndRoleList = from("ProductAndRole")

[MSG]The statement on line 91 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

UnnecessaryGString391

[SRC]productAndRoleList = from("ProductAndRole")

[MSG]The String 'ProductAndRole' can be wrapped in single quotes instead of double quotes

TrailingWhitespace392

[SRC].where("productId", sprint.productId, "partyId", userLog..TAKEHOLDER",

[MSG]Line ends with whitespace characters

UnnecessaryGString392

[SRC].where("productId", sprint.productId, "partyId", userLog..TAKEHOLDER",

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString392

[SRC].where("productId", sprint.productId, "partyId", userLog..TAKEHOLDER",

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString392

[SRC].where("productId", sprint.productId, "partyId", userLog..TAKEHOLDER",

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString392

[SRC].where("productId", sprint.productId, "partyId", userLog..TAKEHOLDER",

[MSG]The String 'STAKEHOLDER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString393

[SRC]"supportDiscontinuationDate", null, "thruDate", null)

[MSG]The String 'supportDiscontinuationDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString393

[SRC]"supportDiscontinuationDate", null, "thruDate", null)

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

Indentation395

[SRC]if (productAndRoleList) {

[MSG]The statement on line 95 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

Indentation396

[SRC]ismember = true

[MSG]The statement on line 96 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [25, 29, 33] but was 24

SpaceAfterIf399

[SRC]} else if("SCRUM_MASTER".equals(groupId)) {

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

UnnecessaryGString399

[SRC]} else if("SCRUM_MASTER".equals(groupId)) {

[MSG]The String 'SCRUM_MASTER' can be wrapped in single quotes instead of double quotes

Indentation3101

[SRC]productRoleList = []

[MSG]The statement on line 101 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

Indentation3102

[SRC]productRoleList = from("ProductAndRole")

[MSG]The statement on line 102 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

UnnecessaryGString3102

[SRC]productRoleList = from("ProductAndRole")

[MSG]The String 'ProductAndRole' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon3103

[SRC].where("productId" : sprint.productId, "partyId" : userLogin.partyId,

[MSG]The colon for the literal Map entry for key [productId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3103

[SRC].where("productId" : sprint.productId, "partyId" : userLogin.partyId,

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

TrailingWhitespace3103

[SRC].where("productId" : sprint.productId, "partyId" : userLogin.partyId,

[MSG]Line ends with whitespace characters

UnnecessaryGString3103

[SRC].where("productId" : sprint.productId, "partyId" : userLogin.partyId,

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3103

[SRC].where("productId" : sprint.productId, "partyId" : userLogin.partyId,

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon3104

[SRC]"roleTypeId" : "SCRUM_MASTER", "supportDiscontinuationDa..ate" : null)

[MSG]The colon for the literal Map entry for key [roleTypeId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3104

[SRC]"roleTypeId" : "SCRUM_MASTER", "supportDiscontinuationDa..ate" : null)

[MSG]The colon for the literal Map entry for key [supportDiscontinuationDate] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3104

[SRC]"roleTypeId" : "SCRUM_MASTER", "supportDiscontinuationDa..ate" : null)

[MSG]The colon for the literal Map entry for key [thruDate] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3104

[SRC]"roleTypeId" : "SCRUM_MASTER", "supportDiscontinuationDa..ate" : null)

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3104

[SRC]"roleTypeId" : "SCRUM_MASTER", "supportDiscontinuationDa..ate" : null)

[MSG]The String 'SCRUM_MASTER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3104

[SRC]"roleTypeId" : "SCRUM_MASTER", "supportDiscontinuationDa..ate" : null)

[MSG]The String 'supportDiscontinuationDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3104

[SRC]"roleTypeId" : "SCRUM_MASTER", "supportDiscontinuationDa..ate" : null)

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

TrailingWhitespace3106

[SRC]

[MSG]Line ends with whitespace characters

Indentation3107

[SRC]if (productRoleList) {

[MSG]The statement on line 107 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

Indentation3108

[SRC]ismember = true

[MSG]The statement on line 108 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

Indentation3111

[SRC]if (ismember == false) {

[MSG]The statement on line 111 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

Indentation3112

[SRC]projectPartyAssignment = from("WorkEffortPartyAssignment...queryList()

[MSG]The statement on line 112 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

UnnecessaryGString3112

[SRC]projectPartyAssignment = from("WorkEffortPartyAssignment...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3112

[SRC]projectPartyAssignment = from("WorkEffortPartyAssignment...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3112

[SRC]projectPartyAssignment = from("WorkEffortPartyAssignment...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

Indentation3113

[SRC]if (projectPartyAssignment) {

[MSG]The statement on line 113 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

Indentation3114

[SRC]ismember = true

[MSG]The statement on line 114 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [25, 29, 33] but was 24

Indentation3118

[SRC]if (ismember == false) {

[MSG]The statement on line 118 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

Indentation3119

[SRC]allSprintList = []

[MSG]The statement on line 119 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

Indentation3120

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The statement on line 120 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

UnnecessaryGString3120

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3120

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The String 'workEffortParentId' can be wrapped in single quotes instead of double quotes

Indentation3121

[SRC]allSprintList.each { SprintListMap ->

[MSG]The statement on line 121 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

Indentation3122

[SRC]sprintId = SprintListMap.workEffortId

[MSG]The statement on line 122 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [25, 29, 33] or one of [37, 41, 45] columns, but was 24

Indentation3123

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The statement on line 123 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [25, 29, 33] or one of [37, 41, 45] columns, but was 24

UnnecessaryGString3123

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3123

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3123

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

Indentation3124

[SRC]if (workEffortPartyAssignment) {

[MSG]The statement on line 124 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [25, 29, 33] or one of [37, 41, 45] columns, but was 24

Indentation3125

[SRC]ismember = true

[MSG]The statement on line 125 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [29, 33, 37] but was 28

Indentation3130

[SRC]allSprintList = []

[MSG]The statement on line 130 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

Indentation3131

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The statement on line 131 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

UnnecessaryGString3131

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3131

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The String 'workEffortParentId' can be wrapped in single quotes instead of double quotes

Indentation3132

[SRC]allSprintList.each { SprintListMap ->

[MSG]The statement on line 132 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

Indentation3133

[SRC]sprintId = SprintListMap.workEffortId

[MSG]The statement on line 133 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [21, 25, 29] or one of [33, 37, 41] columns, but was 20

Indentation3134

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The statement on line 134 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [21, 25, 29] or one of [33, 37, 41] columns, but was 20

UnnecessaryGString3134

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3134

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3134

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

Indentation3135

[SRC]if (workEffortPartyAssignment) {

[MSG]The statement on line 135 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [21, 25, 29] or one of [33, 37, 41] columns, but was 20

Indentation3136

[SRC]ismember = true

[MSG]The statement on line 136 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [25, 29, 33] but was 24

TrailingWhitespace3141

[SRC]if (security.hasEntityPermission("SCRUM", "_ADMIN", session)

[MSG]Line ends with whitespace characters

UnnecessaryGString3141

[SRC]if (security.hasEntityPermission("SCRUM", "_ADMIN", session)

[MSG]The String 'SCRUM' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3141

[SRC]if (security.hasEntityPermission("SCRUM", "_ADMIN", session)

[MSG]The String '_ADMIN' can be wrapped in single quotes instead of double quotes

TrailingWhitespace3142

[SRC]|| ((security.hasEntityPermission("SCRUM", "_ROLE_ADMIN"..W", session)

[MSG]Line ends with whitespace characters

UnnecessaryGString3142

[SRC]|| ((security.hasEntityPermission("SCRUM", "_ROLE_ADMIN"..W", session)

[MSG]The String 'SCRUM' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3142

[SRC]|| ((security.hasEntityPermission("SCRUM", "_ROLE_ADMIN"..W", session)

[MSG]The String '_ROLE_ADMIN' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3142

[SRC]|| ((security.hasEntityPermission("SCRUM", "_ROLE_ADMIN"..W", session)

[MSG]The String 'SCRUM' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3142

[SRC]|| ((security.hasEntityPermission("SCRUM", "_ROLE_ADMIN"..W", session)

[MSG]The String '_ROLE_VIEW' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3143

[SRC]|| security.hasEntityPermission("SCRUM_PROJECT", "_ROLE_..W", session)

[MSG]The String 'SCRUM_PROJECT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3143

[SRC]|| security.hasEntityPermission("SCRUM_PROJECT", "_ROLE_..W", session)

[MSG]The String '_ROLE_ADMIN' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3143

[SRC]|| security.hasEntityPermission("SCRUM_PROJECT", "_ROLE_..W", session)

[MSG]The String 'SCRUM_PROJECT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3143

[SRC]|| security.hasEntityPermission("SCRUM_PROJECT", "_ROLE_..W", session)

[MSG]The String '_ROLE_VIEW' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3144

[SRC]|| security.hasEntityPermission("SCRUM_PROJECT", "_VIEW"..ismember)) {

[MSG]The String 'SCRUM_PROJECT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3144

[SRC]|| security.hasEntityPermission("SCRUM_PROJECT", "_VIEW"..ismember)) {

[MSG]The String '_VIEW' can be wrapped in single quotes instead of double quotes

Indentation3145

[SRC]sprints.add(sprint)

[MSG]The statement on line 145 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [13, 17, 21] but was 16

Indentation3146

[SRC]countSprint++

[MSG]The statement on line 146 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [13, 17, 21] but was 16

TrailingWhitespace3148

[SRC]} else {

[MSG]Line ends with whitespace characters

Indentation3149

[SRC]if (countSprint < 4) {

[MSG]The statement on line 149 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [9, 13, 17] but was 6

Indentation3150

[SRC]ismember = false

[MSG]The statement on line 150 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [13, 17, 21] but was 12

Indentation3151

[SRC]if (partyAndSecurityGroupList) {

[MSG]The statement on line 151 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [13, 17, 21] but was 12

Indentation3152

[SRC]groupId = partyAndSecurityGroupList[0].groupId

[MSG]The statement on line 152 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

Indentation3153

[SRC]if ("SCRUM_PRODUCT_OWNER".equals(groupId)) {

[MSG]The statement on line 153 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

SpaceAfterClosingBrace3153

[SRC]if ("SCRUM_PRODUCT_OWNER".equals(groupId)) {

[MSG]The closing brace for the block in class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

UnnecessaryGString3153

[SRC]if ("SCRUM_PRODUCT_OWNER".equals(groupId)) {

[MSG]The String 'SCRUM_PRODUCT_OWNER' can be wrapped in single quotes instead of double quotes

Indentation3154

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]The statement on line 154 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

UnnecessaryGString3154

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]The String 'ProductRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3154

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3154

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3154

[SRC]productAndRoleList = from("ProductRole").where("productI...queryList()

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

Indentation3155

[SRC]if (productAndRoleList) {

[MSG]The statement on line 155 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

Indentation3156

[SRC]ismember = true

[MSG]The statement on line 156 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [25, 29, 33] but was 24

SpaceAfterIf3158

[SRC]}else if("SCRUM_STAKEHOLDER".equals(groupId)) {

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

UnnecessaryGString3158

[SRC]}else if("SCRUM_STAKEHOLDER".equals(groupId)) {

[MSG]The String 'SCRUM_STAKEHOLDER' can be wrapped in single quotes instead of double quotes

Indentation3160

[SRC]scrumRolesCond = EntityCondition.makeCondition([

[MSG]The statement on line 160 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 24

UnnecessaryGString3161

[SRC]EntityCondition.makeCondition ("partyId", EntityOperator..in.partyId),

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3162

[SRC]EntityCondition.makeCondition ("roleTypeId", EntityOpera..AKEHOLDER"),

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3162

[SRC]EntityCondition.makeCondition ("roleTypeId", EntityOpera..AKEHOLDER"),

[MSG]The String 'STAKEHOLDER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3163

[SRC]EntityCondition.makeCondition ("partyStatusId", EntityOp.._DISABLED"),

[MSG]The String 'partyStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3163

[SRC]EntityCondition.makeCondition ("partyStatusId", EntityOp.._DISABLED"),

[MSG]The String 'PARTY_DISABLED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3164

[SRC]EntityCondition.makeCondition ("thruDate", EntityOperato..QUALS, null)

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

Indentation3166

[SRC]scrumRolesPersonAndCompanyList = from("ScrumRolesPersonA...queryList()

[MSG]The statement on line 166 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 24

UnnecessaryGString3166

[SRC]scrumRolesPersonAndCompanyList = from("ScrumRolesPersonA...queryList()

[MSG]The String 'ScrumRolesPersonAndCompany' can be wrapped in single quotes instead of double quotes

Indentation3167

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The statement on line 167 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 24

UnnecessaryGString3167

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The String 'ProductRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3167

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3167

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3167

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The String 'PRODUCT_OWNER_COMP' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3167

[SRC]productRoleList = from("ProductRole").where("partyId", s...queryList()

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

Indentation3168

[SRC]if (productRoleList) {

[MSG]The statement on line 168 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 24

Indentation3169

[SRC]productRoleList.each { productRoleMap ->

[MSG]The statement on line 169 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [25, 29, 33] but was 28

Indentation3170

[SRC]stakeholderProduct = productRoleMap.productId

[MSG]The statement on line 170 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [29, 33, 37] or one of [47, 51, 55] columns, but was 32

Indentation3171

[SRC]if (stakeholderProduct.equals(sprint.productId)) {

[MSG]The statement on line 171 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [29, 33, 37] or one of [47, 51, 55] columns, but was 32

Indentation3172

[SRC]ismember = true

[MSG]The statement on line 172 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [33, 37, 41] but was 36

Indentation3177

[SRC]if (ismember == false) {

[MSG]The statement on line 177 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 24

Indentation3178

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The statement on line 178 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [25, 29, 33] but was 28

SpaceAroundMapEntryColon3178

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The colon for the literal Map entry for key [productId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3178

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3178

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The colon for the literal Map entry for key [roleTypeId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3178

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The colon for the literal Map entry for key [supportDiscontinuationDate] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3178

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The colon for the literal Map entry for key [thruDate] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3178

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The String 'ProductAndRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3178

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3178

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3178

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3178

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The String 'STAKEHOLDER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3178

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The String 'supportDiscontinuationDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3178

[SRC]productAndRoleList = from("ProductAndRole").where("produ...queryList()

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

Indentation3179

[SRC]if (productAndRoleList) {

[MSG]The statement on line 179 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [25, 29, 33] but was 28

Indentation3180

[SRC]ismember = true

[MSG]The statement on line 180 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [29, 33, 37] but was 32

SpaceAfterIf3183

[SRC]} else if("SCRUM_MASTER".equals(groupId)) {

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

UnnecessaryGString3183

[SRC]} else if("SCRUM_MASTER".equals(groupId)) {

[MSG]The String 'SCRUM_MASTER' can be wrapped in single quotes instead of double quotes

Indentation3185

[SRC]productRoleList = []

[MSG]The statement on line 185 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 24

Indentation3186

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The statement on line 186 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 24

SpaceAroundMapEntryColon3186

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The colon for the literal Map entry for key [productId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3186

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3186

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The colon for the literal Map entry for key [roleTypeId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3186

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The colon for the literal Map entry for key [supportDiscontinuationDate] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon3186

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The colon for the literal Map entry for key [thruDate] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString3186

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The String 'ProductAndRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3186

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3186

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3186

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3186

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The String 'SCRUM_MASTER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3186

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The String 'supportDiscontinuationDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3186

[SRC]productRoleList = from("ProductAndRole").where("productI...queryList()

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

Indentation3187

[SRC]if (productRoleList) {

[MSG]The statement on line 187 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 24

Indentation3188

[SRC]ismember = true

[MSG]The statement on line 188 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [25, 29, 33] but was 28

Indentation3191

[SRC]if (ismember == false) {

[MSG]The statement on line 191 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 24

Indentation3192

[SRC]projectPartyAssignment = from("WorkEffortPartyAssignment...queryList()

[MSG]The statement on line 192 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [25, 29, 33] but was 28

UnnecessaryGString3192

[SRC]projectPartyAssignment = from("WorkEffortPartyAssignment...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3192

[SRC]projectPartyAssignment = from("WorkEffortPartyAssignment...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3192

[SRC]projectPartyAssignment = from("WorkEffortPartyAssignment...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

Indentation3193

[SRC]if (projectPartyAssignment) {

[MSG]The statement on line 193 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [25, 29, 33] but was 28

Indentation3194

[SRC]ismember = true

[MSG]The statement on line 194 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [29, 33, 37] but was 32

Indentation3198

[SRC]if (ismember == false) {

[MSG]The statement on line 198 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 24

Indentation3199

[SRC]allSprintList = []

[MSG]The statement on line 199 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [25, 29, 33] but was 28

Indentation3200

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The statement on line 200 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [25, 29, 33] but was 28

UnnecessaryGString3200

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3200

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The String 'workEffortParentId' can be wrapped in single quotes instead of double quotes

Indentation3201

[SRC]allSprintList.each { SprintListMap ->

[MSG]The statement on line 201 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [25, 29, 33] but was 28

Indentation3202

[SRC]sprintId = SprintListMap.workEffortId

[MSG]The statement on line 202 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [29, 33, 37] or one of [45, 49, 53] columns, but was 32

Indentation3203

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The statement on line 203 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [29, 33, 37] or one of [45, 49, 53] columns, but was 32

UnnecessaryGString3203

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3203

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3203

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

Indentation3204

[SRC]if (workEffortPartyAssignment) {

[MSG]The statement on line 204 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [29, 33, 37] or one of [45, 49, 53] columns, but was 32

Indentation3205

[SRC]ismember = true

[MSG]The statement on line 205 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [33, 37, 41] but was 36

Indentation3210

[SRC]allSprintList = []

[MSG]The statement on line 210 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

Indentation3211

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The statement on line 211 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

UnnecessaryGString3211

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3211

[SRC]allSprintList = from("WorkEffort").where("workEffortPare...queryList()

[MSG]The String 'workEffortParentId' can be wrapped in single quotes instead of double quotes

Indentation3212

[SRC]allSprintList.each { SprintListMap ->

[MSG]The statement on line 212 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

Indentation3213

[SRC]sprintId = SprintListMap.workEffortId

[MSG]The statement on line 213 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [25, 29, 33] or one of [37, 41, 45] columns, but was 24

Indentation3214

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The statement on line 214 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [25, 29, 33] or one of [37, 41, 45] columns, but was 24

UnnecessaryGString3214

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3214

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3214

[SRC]workEffortPartyAssignment = from("WorkEffortPartyAssignm...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

Indentation3215

[SRC]if (workEffortPartyAssignment) {

[MSG]The statement on line 215 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [25, 29, 33] or one of [37, 41, 45] columns, but was 24

Indentation3216

[SRC]ismember = true

[MSG]The statement on line 216 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [29, 33, 37] but was 28

TrailingWhitespace3221

[SRC]if (security.hasEntityPermission("SCRUM", "_ADMIN", session)

[MSG]Line ends with whitespace characters

UnnecessaryGString3221

[SRC]if (security.hasEntityPermission("SCRUM", "_ADMIN", session)

[MSG]The String 'SCRUM' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3221

[SRC]if (security.hasEntityPermission("SCRUM", "_ADMIN", session)

[MSG]The String '_ADMIN' can be wrapped in single quotes instead of double quotes

TrailingWhitespace3222

[SRC]|| ((security.hasEntityPermission("SCRUM", "_ROLE_ADMIN"..W", session)

[MSG]Line ends with whitespace characters

UnnecessaryGString3222

[SRC]|| ((security.hasEntityPermission("SCRUM", "_ROLE_ADMIN"..W", session)

[MSG]The String 'SCRUM' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3222

[SRC]|| ((security.hasEntityPermission("SCRUM", "_ROLE_ADMIN"..W", session)

[MSG]The String '_ROLE_ADMIN' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3222

[SRC]|| ((security.hasEntityPermission("SCRUM", "_ROLE_ADMIN"..W", session)

[MSG]The String 'SCRUM' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3222

[SRC]|| ((security.hasEntityPermission("SCRUM", "_ROLE_ADMIN"..W", session)

[MSG]The String '_ROLE_VIEW' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3223

[SRC]|| security.hasEntityPermission("SCRUM_PROJECT", "_ROLE_..W", session)

[MSG]The String 'SCRUM_PROJECT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3223

[SRC]|| security.hasEntityPermission("SCRUM_PROJECT", "_ROLE_..W", session)

[MSG]The String '_ROLE_ADMIN' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3223

[SRC]|| security.hasEntityPermission("SCRUM_PROJECT", "_ROLE_..W", session)

[MSG]The String 'SCRUM_PROJECT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3223

[SRC]|| security.hasEntityPermission("SCRUM_PROJECT", "_ROLE_..W", session)

[MSG]The String '_ROLE_VIEW' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3224

[SRC]|| security.hasEntityPermission("SCRUM_PROJECT", "_VIEW"..ismember)) {

[MSG]The String 'SCRUM_PROJECT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3224

[SRC]|| security.hasEntityPermission("SCRUM_PROJECT", "_VIEW"..ismember)) {

[MSG]The String '_VIEW' can be wrapped in single quotes instead of double quotes

Indentation3225

[SRC]sprints.add(sprint)

[MSG]The statement on line 225 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 14

Indentation3226

[SRC]countSprint++

[MSG]The statement on line 226 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 14

Indentation3232

[SRC]sprints = UtilMisc.sortMaps(sprints, ["companyName", "pr..oductName"])

[MSG]The statement on line 232 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 2

UnnecessaryGString3232

[SRC]sprints = UtilMisc.sortMaps(sprints, ["companyName", "pr..oductName"])

[MSG]The String 'companyName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3232

[SRC]sprints = UtilMisc.sortMaps(sprints, ["companyName", "pr..oductName"])

[MSG]The String 'projectName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3232

[SRC]sprints = UtilMisc.sortMaps(sprints, ["companyName", "pr..oductName"])

[MSG]The String 'productName' can be wrapped in single quotes instead of double quotes

➥ ListRevision.groovy

Rule NamePriorityLine #Source Line / Message
SpaceAroundOperator330

[SRC]if ((parameters.productId != null)||(parameters.custRequ..ndex > 0)) {

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator330

[SRC]if ((parameters.productId != null)||(parameters.custRequ..ndex > 0)) {

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator330

[SRC]if ((parameters.productId != null)||(parameters.custRequ..ndex > 0)) {

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator330

[SRC]if ((parameters.productId != null)||(parameters.custRequ..ndex > 0)) {

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator330

[SRC]if ((parameters.productId != null)||(parameters.custRequ..ndex > 0)) {

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator330

[SRC]if ((parameters.productId != null)||(parameters.custRequ..ndex > 0)) {

[MSG]The operator "||" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

UnnecessaryGString332

[SRC]orList.add(EntityCondition.makeCondition("custRequestTyp..D_BACKLOG"))

[MSG]The String 'custRequestTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]orList.add(EntityCondition.makeCondition("custRequestTyp..D_BACKLOG"))

[MSG]The String 'RF_PROD_BACKLOG' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]orList.add(EntityCondition.makeCondition("custRequestTyp..N_BACKLOG"))

[MSG]The String 'custRequestTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]orList.add(EntityCondition.makeCondition("custRequestTyp..N_BACKLOG"))

[MSG]The String 'RF_UNPLAN_BACKLOG' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]andList.add(EntityCondition.makeCondition("productId", E..ctId + "%"))

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]andList.add(EntityCondition.makeCondition("productId", E..ctId + "%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

UnnecessaryGString339

[SRC]andList.add(EntityCondition.makeCondition("custRequestId..stId + "%"))

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString339

[SRC]andList.add(EntityCondition.makeCondition("custRequestId..stId + "%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]custRequestList = from("CustRequestAndCustRequestItem")....queryList()

[MSG]The String 'CustRequestAndCustRequestItem' can be wrapped in single quotes instead of double quotes

TrailingWhitespace344

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString345

[SRC]custRequestIds = EntityUtil.getFieldListFromEntityList(c..stId", true)

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]taskOrList.add(EntityCondition.makeCondition("workEffort..ASK_ERROR"))

[MSG]The String 'workEffortTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]taskOrList.add(EntityCondition.makeCondition("workEffort..ASK_ERROR"))

[MSG]The String 'SCRUM_TASK_ERROR' can be wrapped in single quotes instead of double quotes

UnnecessaryGString348

[SRC]taskOrList.add(EntityCondition.makeCondition("workEffort..TASK_TEST"))

[MSG]The String 'workEffortTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString348

[SRC]taskOrList.add(EntityCondition.makeCondition("workEffort..TASK_TEST"))

[MSG]The String 'SCRUM_TASK_TEST' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]taskOrList.add(EntityCondition.makeCondition("workEffort..TASK_IMPL"))

[MSG]The String 'workEffortTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString349

[SRC]taskOrList.add(EntityCondition.makeCondition("workEffort..TASK_IMPL"))

[MSG]The String 'SCRUM_TASK_IMPL' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]taskOrList.add(EntityCondition.makeCondition("workEffort..TASK_INST"))

[MSG]The String 'workEffortTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]taskOrList.add(EntityCondition.makeCondition("workEffort..TASK_INST"))

[MSG]The String 'SCRUM_TASK_INST' can be wrapped in single quotes instead of double quotes

UnnecessaryGString352

[SRC]taskAndList.add(EntityCondition.makeCondition("custReque..RequestIds))

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]custAndWorkEffortList = from("CustRequestAndWorkEffort")...queryList()

[MSG]The String 'CustRequestAndWorkEffort' can be wrapped in single quotes instead of double quotes

TrailingWhitespace356

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString358

[SRC]workEffortIds = EntityUtil.getFieldListFromEntityList(cu..rtId", true)

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]revisionAndList.add(EntityCondition.makeCondition("workE..rtId + "%"))

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]revisionAndList.add(EntityCondition.makeCondition("workE..rtId + "%"))

[MSG]The String '%' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]revisionAndList.add(EntityCondition.makeCondition("workE..kEffortIds))

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]revisionAndList.add(EntityCondition.makeCondition("workE.._SUB_INFO"))

[MSG]The String 'workEffortContentTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString365

[SRC]revisionAndList.add(EntityCondition.makeCondition("workE.._SUB_INFO"))

[MSG]The String 'TASK_SUB_INFO' can be wrapped in single quotes instead of double quotes

UnnecessaryGString367

[SRC]revisionList = from("WorkEffortAndContentDataResource")....queryList()

[MSG]The String 'WorkEffortAndContentDataResource' can be wrapped in single quotes instead of double quotes

UnnecessaryGString367

[SRC]revisionList = from("WorkEffortAndContentDataResource")....queryList()

[MSG]The String '-fromDate' can be wrapped in single quotes instead of double quotes

TrailingWhitespace368

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString378

[SRC]custAndWorkEfffList = from("CustRequestAndWorkEffort").w...queryList()

[MSG]The String 'CustRequestAndWorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString378

[SRC]custAndWorkEfffList = from("CustRequestAndWorkEffort").w...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString381

[SRC]custAndCustItemList = from("CustRequestAndCustRequestIte...queryList()

[MSG]The String 'CustRequestAndCustRequestItem' can be wrapped in single quotes instead of double quotes

UnnecessaryGString381

[SRC]custAndCustItemList = from("CustRequestAndCustRequestIte...queryList()

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

➥ ListScrumPreferenceSecurityGroup.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGString330

[SRC]andCond.add(EntityCondition.makeCondition("partyId", Ent..S, partyId))

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString331

[SRC]andCond.add(EntityCondition.makeCondition("partyStatusId..Y_ENABLED"))

[MSG]The String 'partyStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString331

[SRC]andCond.add(EntityCondition.makeCondition("partyStatusId..Y_ENABLED"))

[MSG]The String 'PARTY_ENABLED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]orCond.add(EntityCondition.makeCondition("groupId", Enti..UCT_OWNER"))

[MSG]The String 'groupId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]orCond.add(EntityCondition.makeCondition("groupId", Enti..UCT_OWNER"))

[MSG]The String 'SCRUM_PRODUCT_OWNER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]orCond.add(EntityCondition.makeCondition("groupId", Enti..UM_MASTER"))

[MSG]The String 'groupId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]orCond.add(EntityCondition.makeCondition("groupId", Enti..UM_MASTER"))

[MSG]The String 'SCRUM_MASTER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]orCond.add(EntityCondition.makeCondition("groupId", Enti..CRUM_TEAM"))

[MSG]The String 'groupId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]orCond.add(EntityCondition.makeCondition("groupId", Enti..CRUM_TEAM"))

[MSG]The String 'SCRUM_TEAM' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]orCond.add(EntityCondition.makeCondition("enabled", Enti..QUALS, "Y"))

[MSG]The String 'enabled' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]orCond.add(EntityCondition.makeCondition("enabled", Enti..QUALS, "Y"))

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]orCond.add(EntityCondition.makeCondition("enabled", Enti..UALS, null))

[MSG]The String 'enabled' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]scrumUserLoginSecurityGroupList = from("ScrumMemberUserL...queryList()

[MSG]The String 'ScrumMemberUserLoginAndSecurityGroup' can be wrapped in single quotes instead of double quotes

InvertedCondition352

[SRC]if ("SCRUM_PRODUCT_OWNER" == scrumUserLoginSecurityGroupMap.groupId) {

[MSG]SCRUM_PRODUCT_OWNER is a constant expression on the left side of a compare equals operation

UnnecessaryGString352

[SRC]if ("SCRUM_PRODUCT_OWNER" == scrumUserLoginSecurityGroupMap.groupId) {

[MSG]The String 'SCRUM_PRODUCT_OWNER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString354

[SRC]ownerCond.add(EntityCondition.makeCondition("enumTypeId"..REFERENCE"))

[MSG]The String 'enumTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString354

[SRC]ownerCond.add(EntityCondition.makeCondition("enumTypeId"..REFERENCE"))

[MSG]The String 'SCRUM_PREFERENCE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]ownerCond.add(EntityCondition.makeCondition("enumId", En..ER_NOTIFY"))

[MSG]The String 'enumId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString355

[SRC]ownerCond.add(EntityCondition.makeCondition("enumId", En..ER_NOTIFY"))

[MSG]The String 'MASTER_NOTIFY' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]userPreferenceList = from("Enumeration").where(ownerConds).queryList()

[MSG]The String 'Enumeration' can be wrapped in single quotes instead of double quotes

InvertedCondition358

[SRC]} else if ("SCRUM_MASTER" == scrumUserLoginSecurityGroupMap.groupId) {

[MSG]SCRUM_MASTER is a constant expression on the left side of a compare equals operation

UnnecessaryGString358

[SRC]} else if ("SCRUM_MASTER" == scrumUserLoginSecurityGroupMap.groupId) {

[MSG]The String 'SCRUM_MASTER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]masterCond.add(EntityCondition.makeCondition("enumTypeId..REFERENCE"))

[MSG]The String 'enumTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]masterCond.add(EntityCondition.makeCondition("enumTypeId..REFERENCE"))

[MSG]The String 'SCRUM_PREFERENCE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]masterCond.add(EntityCondition.makeCondition("enumId", E..ER_NOTIFY"))

[MSG]The String 'enumId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]masterCond.add(EntityCondition.makeCondition("enumId", E..ER_NOTIFY"))

[MSG]The String 'MASTER_NOTIFY' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]userPreferenceList = from("Enumeration").where(masterCon...queryList()

[MSG]The String 'Enumeration' can be wrapped in single quotes instead of double quotes

SpaceAfterClosingBrace372

[SRC]userPreferenceList.each { userPreferenceMap ->

[MSG]The closing brace for the closure in class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

UnnecessaryGString379

[SRC]if (security.hasEntityPermission("SCRUM", "_ADMIN", session)) {

[MSG]The String 'SCRUM' can be wrapped in single quotes instead of double quotes

UnnecessaryGString379

[SRC]if (security.hasEntityPermission("SCRUM", "_ADMIN", session)) {

[MSG]The String '_ADMIN' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]userPreferenceList = from("Enumeration").where("enumType...queryList()

[MSG]The String 'Enumeration' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]userPreferenceList = from("Enumeration").where("enumType...queryList()

[MSG]The String 'enumTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]userPreferenceList = from("Enumeration").where("enumType...queryList()

[MSG]The String 'SCRUM_PREFERENCE' can be wrapped in single quotes instead of double quotes

➥ ListScrumResource.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod252

[SRC]if (!"N".equals(result.enabled)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to N.equals(result.enabled) method can be rewritten as (N == (result.enabled))

UnnecessaryGString324

[SRC]performFindInMap.entityName = "ScrumMemberUserLoginAndSecurityGroup"

[MSG]The String 'ScrumMemberUserLoginAndSecurityGroup' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]performFindInMap.noConditionFind = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]performFindInMap.filterByDate = "Y"

[MSG]The String 'Y' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]performFindInMap.orderBy = "lastName"

[MSG]The String 'lastName' can be wrapped in single quotes instead of double quotes

Indentation346

[SRC]logError(e)

[MSG]The statement on line 46 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 17

UnnecessaryParenthesesForMethodCallWithClosure351

[SRC]resultList.each() { result ->

[MSG]Violation in class org.apache.ofbiz.scrum.None. Parentheses in the 'each' method call are unnecessary and can be removed.

UnnecessaryGString352

[SRC]if (!"N".equals(result.enabled)) {

[MSG]The String 'N' can be wrapped in single quotes instead of double quotes

➥ ListScrumRolesPersonAndCompany.groovy

Rule NamePriorityLine #Source Line / Message
SpaceAroundMapEntryColon329

[SRC]productRoleList = from("ProductRole").where("productId" ...queryList()

[MSG]The colon for the literal Map entry for key [productId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon329

[SRC]productRoleList = from("ProductRole").where("productId" ...queryList()

[MSG]The colon for the literal Map entry for key [roleTypeId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString329

[SRC]productRoleList = from("ProductRole").where("productId" ...queryList()

[MSG]The String 'ProductRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]productRoleList = from("ProductRole").where("productId" ...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]productRoleList = from("ProductRole").where("productId" ...queryList()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]productRoleList = from("ProductRole").where("productId" ...queryList()

[MSG]The String 'PRODUCT_OWNER_COMP' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]EntityCondition.makeCondition ("roleTypeId", EntityOpera..UCT_OWNER"),

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]EntityCondition.makeCondition ("roleTypeId", EntityOpera..UCT_OWNER"),

[MSG]The String 'PRODUCT_OWNER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]EntityCondition.makeCondition ("partyIdFrom", EntityOper..0].partyId),

[MSG]The String 'partyIdFrom' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]EntityCondition.makeCondition ("partyStatusId", EntityOp.._DISABLED"),

[MSG]The String 'partyStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]EntityCondition.makeCondition ("partyStatusId", EntityOp.._DISABLED"),

[MSG]The String 'PARTY_DISABLED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]EntityCondition.makeCondition ("thruDate", EntityOperato..QUALS, null)

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]personAndCompanyList = from("ScrumRolesPersonAndCompany"...queryList()

[MSG]The String 'ScrumRolesPersonAndCompany' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]personAndCompanyList = from("ScrumRolesPersonAndCompany"...queryList()

[MSG]The String 'groupName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]EntityCondition.makeCondition ("roleTypeId", EntityOpera..UCT_OWNER"),

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString350

[SRC]EntityCondition.makeCondition ("roleTypeId", EntityOpera..UCT_OWNER"),

[MSG]The String 'PRODUCT_OWNER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString351

[SRC]EntityCondition.makeCondition ("partyStatusId", EntityOp.._DISABLED"),

[MSG]The String 'partyStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString351

[SRC]EntityCondition.makeCondition ("partyStatusId", EntityOp.._DISABLED"),

[MSG]The String 'PARTY_DISABLED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString352

[SRC]EntityCondition.makeCondition ("thruDate", EntityOperato..QUALS, null)

[MSG]The String 'thruDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString354

[SRC]personAndCompanyList = from("ScrumRolesPersonAndCompany"...queryList()

[MSG]The String 'ScrumRolesPersonAndCompany' can be wrapped in single quotes instead of double quotes

UnnecessaryGString354

[SRC]personAndCompanyList = from("ScrumRolesPersonAndCompany"...queryList()

[MSG]The String 'groupName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString359

[SRC]EntityCondition.makeCondition ("partyId", EntityOperator..S, partyId),

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]EntityCondition.makeCondition ("partyStatusId", EntityOp..Y_DISABLED")

[MSG]The String 'partyStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]EntityCondition.makeCondition ("partyStatusId", EntityOp..Y_DISABLED")

[MSG]The String 'PARTY_DISABLED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString362

[SRC]securityGroupList = from("ScrumMemberUserLoginAndSecurit...queryList()

[MSG]The String 'ScrumMemberUserLoginAndSecurityGroup' can be wrapped in single quotes instead of double quotes

➥ ListTimeSheets.groovy

Rule NamePriorityLine #Source Line / Message
AssignmentInConditional261

[SRC]while ((emplLeaveMap = emplLeaveList.next())) {

[MSG]Assignment used as conditional value, which always results in true. Use the == operator instead

LineLength264

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The line exceeds 150 characters. The line is 167 characters.

CouldBeElvis331

[SRC]if (!parameters.noConditionFind) {

[MSG]Code could use elvis operator: parameters.noConditionFind = parameters.noConditionFind ?: 'N'

UnnecessaryGString332

[SRC]parameters.noConditionFind = "N"

[MSG]The String 'N' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]performFindResults = runService('performFind', ["entityN..Date DESC"])

[MSG]The String 'entityName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]performFindResults = runService('performFind', ["entityN..Date DESC"])

[MSG]The String 'Timesheet' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]performFindResults = runService('performFind', ["entityN..Date DESC"])

[MSG]The String 'inputFields' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]performFindResults = runService('performFind', ["entityN..Date DESC"])

[MSG]The String 'orderBy' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]performFindResults = runService('performFind', ["entityN..Date DESC"])

[MSG]The String 'fromDate DESC' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]logError(e, "Failure in " + module)

[MSG]The String 'Failure in ' can be wrapped in single quotes instead of double quotes

Indentation346

[SRC]logError(e)

[MSG]The statement on line 46 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 17 but was 21

TrailingWhitespace350

[SRC]

[MSG]Line ends with whitespace characters

UnnecessaryGString355

[SRC]leaveExprsList.add(EntityCondition.makeCondition("fromDa..b.fromDate))

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]leaveExprsList.add(EntityCondition.makeCondition("fromDa..b.thruDate))

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]leaveExprsList.add(EntityCondition.makeCondition("partyI..Db.partyId))

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString358

[SRC]emplLeaveList = from("EmplLeave").where(leaveExprsList)...ryIterator()

[MSG]The String 'EmplLeave' can be wrapped in single quotes instead of double quotes

TrailingWhitespace360

[SRC]

[MSG]Line ends with whitespace characters

TrailingWhitespace363

[SRC]resultHour = runService('getPartyLeaveHoursForDate',

[MSG]Line ends with whitespace characters

UnnecessaryGString364

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString364

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString364

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'leaveTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString364

[SRC]["userLogin": parameters.userLogin, "partyId": emplLeave..y.fromDate])

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString373

[SRC]entries = timesheetDb.getRelated("TimeEntry", null, null, false)

[MSG]The String 'TimeEntry' can be wrapped in single quotes instead of double quotes

➥ ListUnplanBacklog.groovy

Rule NamePriorityLine #Source Line / Message
LineLength246

[SRC]unplannedBacklogList = from("UnPlannedBacklogsAndTasks")...queryList()

[MSG]The line exceeds 150 characters. The line is 159 characters.

UnnecessaryGString328

[SRC]if ("Any" != backlogStatusId) {

[MSG]The String 'Any' can be wrapped in single quotes instead of double quotes

Indentation329

[SRC]taskStatusId = "STS_CREATED"

[MSG]The statement on line 29 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

UnnecessaryGString329

[SRC]taskStatusId = "STS_CREATED"

[MSG]The String 'STS_CREATED' can be wrapped in single quotes instead of double quotes

Indentation330

[SRC]orStsExprs.add(EntityCondition.makeCondition("statusId",.._REVIEWED"))

[MSG]The statement on line 30 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

UnnecessaryGString330

[SRC]orStsExprs.add(EntityCondition.makeCondition("statusId",.._REVIEWED"))

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]orStsExprs.add(EntityCondition.makeCondition("statusId",.._REVIEWED"))

[MSG]The String 'CRQ_REVIEWED' can be wrapped in single quotes instead of double quotes

Indentation332

[SRC]orStsExprs.add(EntityCondition.makeCondition("statusId",.._REVIEWED"))

[MSG]The statement on line 32 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

UnnecessaryGString332

[SRC]orStsExprs.add(EntityCondition.makeCondition("statusId",.._REVIEWED"))

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]orStsExprs.add(EntityCondition.makeCondition("statusId",.._REVIEWED"))

[MSG]The String 'CRQ_REVIEWED' can be wrapped in single quotes instead of double quotes

Indentation333

[SRC]orStsExprs.add(EntityCondition.makeCondition("statusId",..COMPLETED"))

[MSG]The statement on line 33 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

UnnecessaryGString333

[SRC]orStsExprs.add(EntityCondition.makeCondition("statusId",..COMPLETED"))

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]orStsExprs.add(EntityCondition.makeCondition("statusId",..COMPLETED"))

[MSG]The String 'CRQ_COMPLETED' can be wrapped in single quotes instead of double quotes

Indentation337

[SRC]orCurentExprs.add(EntityCondition.makeCondition("current..skStatusId))

[MSG]The statement on line 37 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

UnnecessaryGString337

[SRC]orCurentExprs.add(EntityCondition.makeCondition("current..skStatusId))

[MSG]The String 'currentStatusId' can be wrapped in single quotes instead of double quotes

Indentation338

[SRC]orCurentExprs.add(EntityCondition.makeCondition("current..UALS, null))

[MSG]The statement on line 38 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

UnnecessaryGString338

[SRC]orCurentExprs.add(EntityCondition.makeCondition("current..UALS, null))

[MSG]The String 'currentStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString341

[SRC]andExprs.add(EntityCondition.makeCondition("productId", ...productId))

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC]andExprs.add(EntityCondition.makeCondition("custRequestT..N_BACKLOG"))

[MSG]The String 'custRequestTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC]andExprs.add(EntityCondition.makeCondition("custRequestT..N_BACKLOG"))

[MSG]The String 'RF_UNPLAN_BACKLOG' can be wrapped in single quotes instead of double quotes

SpaceAfterComma346

[SRC]unplannedBacklogList = from("UnPlannedBacklogsAndTasks")...queryList()

[MSG]The parameter workEffortTypeId in the call to method orderBy within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma346

[SRC]unplannedBacklogList = from("UnPlannedBacklogsAndTasks")...queryList()

[MSG]The parameter custSequenceNum in the call to method orderBy within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString346

[SRC]unplannedBacklogList = from("UnPlannedBacklogsAndTasks")...queryList()

[MSG]The String 'UnPlannedBacklogsAndTasks' can be wrapped in single quotes instead of double quotes

UnnecessaryGString346

[SRC]unplannedBacklogList = from("UnPlannedBacklogsAndTasks")...queryList()

[MSG]The String '-custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString346

[SRC]unplannedBacklogList = from("UnPlannedBacklogsAndTasks")...queryList()

[MSG]The String 'workEffortTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString346

[SRC]unplannedBacklogList = from("UnPlannedBacklogsAndTasks")...queryList()

[MSG]The String 'custSequenceNum' can be wrapped in single quotes instead of double quotes

➥ ProductBilling.groovy

Rule NamePriorityLine #Source Line / Message
AssignmentInConditional236

[SRC]while (entryItem = entryIterator.next()) {

[MSG]Assignment used as conditional value, which always results in true. Use the == operator instead

ExplicitCallToEqualsMethod238

[SRC]if ("INVOICE_IN_PROCESS".equals(invoice.getString("statusId"))) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to INVOICE_IN_PROCESS.equals(invoice.getString(statusId)) method can be rewritten as (INVOICE_IN_PROCESS == (invoice.getString(statusId)))

ExplicitCallToEqualsMethod271

[SRC]if ("N".equals(includeMeeting)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to N.equals(includeMeeting) method can be rewritten as (N == (includeMeeting))

UnnecessaryGString331

[SRC]EntityCondition.makeCondition("productId", EntityOperato.. productId),

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]EntityCondition.makeCondition("invoiceId", EntityOperato..QUAL, null),

[MSG]The String 'invoiceId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]entryIterator = from("ProjectSprintBacklogTaskAndTimeEnt..ryIterator()

[MSG]The String 'ProjectSprintBacklogTaskAndTimeEntryTimeSheet' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]entryIterator = from("ProjectSprintBacklogTaskAndTimeEnt..ryIterator()

[MSG]The String '-fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]invoice = entryItem.getRelatedOne("Invoice", false)

[MSG]The String 'Invoice' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]if ("INVOICE_IN_PROCESS".equals(invoice.getString("statusId"))) {

[MSG]The String 'INVOICE_IN_PROCESS' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]if ("INVOICE_IN_PROCESS".equals(invoice.getString("statusId"))) {

[MSG]The String 'statusId' can be wrapped in single quotes instead of double quotes

NoDef351

[SRC]def taskConds = UtilMisc.toList(EntityCondition.makeCond...productId))

[MSG]def for declaration should not be used

VariableTypeRequired351

[SRC]def taskConds = UtilMisc.toList(EntityCondition.makeCond...productId))

[MSG]The type is not specified for variable "taskConds"

UnnecessaryGString351

[SRC]def taskConds = UtilMisc.toList(EntityCondition.makeCond...productId))

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString352

[SRC]taskConds.add(EntityCondition.makeCondition("invoiceId", null))

[MSG]The String 'invoiceId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString353

[SRC]taskConds.add(EntityCondition.makeCondition("timesheetSt..COMPLETED"))

[MSG]The String 'timesheetStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString353

[SRC]taskConds.add(EntityCondition.makeCondition("timesheetSt..COMPLETED"))

[MSG]The String 'TIMESHEET_COMPLETED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]fromDate = fromDate + " " + "00:00:00.000"

[MSG]The String ' ' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]fromDate = fromDate + " " + "00:00:00.000"

[MSG]The String '00:00:00.000' can be wrapped in single quotes instead of double quotes

UnnecessaryGString359

[SRC]taskConds.add(EntityCondition.makeCondition("fromDate", ..(fromDate)))

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString364

[SRC]thruDate = thruDate + " " + "00:00:00.000"

[MSG]The String ' ' can be wrapped in single quotes instead of double quotes

UnnecessaryGString364

[SRC]thruDate = thruDate + " " + "00:00:00.000"

[MSG]The String '00:00:00.000' can be wrapped in single quotes instead of double quotes

UnnecessaryGString366

[SRC]taskConds.add(EntityCondition.makeCondition("fromDate", ..(thruDate)))

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]taskConds.add(EntityCondition.makeCondition("fromDate", ..t.thruDate))

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString371

[SRC]if ("N".equals(includeMeeting)) {

[MSG]The String 'N' can be wrapped in single quotes instead of double quotes

UnnecessaryGString372

[SRC]taskConds.add(EntityCondition.makeCondition("custRequest.._MEETINGS"))

[MSG]The String 'custRequestTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString372

[SRC]taskConds.add(EntityCondition.makeCondition("custRequest.._MEETINGS"))

[MSG]The String 'RF_SCRUM_MEETINGS' can be wrapped in single quotes instead of double quotes

NoDef375

[SRC]def sprintTasks = from("ProjectSprintBacklogTaskAndTimeE...queryList()

[MSG]def for declaration should not be used

VariableTypeRequired375

[SRC]def sprintTasks = from("ProjectSprintBacklogTaskAndTimeE...queryList()

[MSG]The type is not specified for variable "sprintTasks"

UnnecessaryGString375

[SRC]def sprintTasks = from("ProjectSprintBacklogTaskAndTimeE...queryList()

[MSG]The String 'ProjectSprintBacklogTaskAndTimeEntryTimeSheet' can be wrapped in single quotes instead of double quotes

NoDef378

[SRC]def cancelledBacklogTasks = from("CancelledBacklogsTaskA...queryList()

[MSG]def for declaration should not be used

VariableTypeRequired378

[SRC]def cancelledBacklogTasks = from("CancelledBacklogsTaskA...queryList()

[MSG]The type is not specified for variable "cancelledBacklogTasks"

UnnecessaryGString378

[SRC]def cancelledBacklogTasks = from("CancelledBacklogsTaskA...queryList()

[MSG]The String 'CancelledBacklogsTaskAndTimeEntryTimeSheet' can be wrapped in single quotes instead of double quotes

NoDef381

[SRC]def unplannedTasks = from("UnPlannedBacklogsTaskAndTimeE...queryList()

[MSG]def for declaration should not be used

VariableTypeRequired381

[SRC]def unplannedTasks = from("UnPlannedBacklogsTaskAndTimeE...queryList()

[MSG]The type is not specified for variable "unplannedTasks"

UnnecessaryGString381

[SRC]def unplannedTasks = from("UnPlannedBacklogsTaskAndTimeE...queryList()

[MSG]The String 'UnPlannedBacklogsTaskAndTimeEntryTimeSheet' can be wrapped in single quotes instead of double quotes

NoDef383

[SRC]def hoursNotYetBilledTasks = []

[MSG]def for declaration should not be used

VariableTypeRequired383

[SRC]def hoursNotYetBilledTasks = []

[MSG]The type is not specified for variable "hoursNotYetBilledTasks"

SpaceAfterComma387

[SRC]context.hoursNotYetBilledTasks = UtilMisc.sortMaps(hours.."fromDate"])

[MSG]The list element custRequestId within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma387

[SRC]context.hoursNotYetBilledTasks = UtilMisc.sortMaps(hours.."fromDate"])

[MSG]The list element taskId within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma387

[SRC]context.hoursNotYetBilledTasks = UtilMisc.sortMaps(hours.."fromDate"])

[MSG]The list element fromDate within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString387

[SRC]context.hoursNotYetBilledTasks = UtilMisc.sortMaps(hours.."fromDate"])

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString387

[SRC]context.hoursNotYetBilledTasks = UtilMisc.sortMaps(hours.."fromDate"])

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString387

[SRC]context.hoursNotYetBilledTasks = UtilMisc.sortMaps(hours.."fromDate"])

[MSG]The String 'taskId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString387

[SRC]context.hoursNotYetBilledTasks = UtilMisc.sortMaps(hours.."fromDate"])

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

UnnecessaryGString390

[SRC]timeEntryList = UtilMisc.sortMaps(hoursNotYetBilledTasks.."fromDate"])

[MSG]The String 'fromDate' can be wrapped in single quotes instead of double quotes

➥ ProductEmail.groovy

Rule NamePriorityLine #Source Line / Message
LineLength258

[SRC]resultsIdTo = runService('getPartyEmail', ["partyId" : d.. userLogin])

[MSG]The line exceeds 150 characters. The line is 154 characters.

LineLength272

[SRC]resultsIdFrom = runService('getPartyEmail', ["partyId" :.. userLogin])

[MSG]The line exceeds 150 characters. The line is 158 characters.

UnusedImport322

[SRC]import org.apache.ofbiz.base.util.UtilValidate

[MSG]The [org.apache.ofbiz.base.util.UtilValidate] import is never referenced

SpaceBeforeOpeningBrace329

[SRC]try{

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

Indentation332

[SRC]context.product = from("Product").where("productId", pro..).queryOne()

[MSG]The statement on line 32 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 9

UnnecessaryGString332

[SRC]context.product = from("Product").where("productId", pro..).queryOne()

[MSG]The String 'Product' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]context.product = from("Product").where("productId", pro..).queryOne()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]communicationEvent = from("CommunicationEvent").where("c..).queryOne()

[MSG]The String 'CommunicationEvent' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]communicationEvent = from("CommunicationEvent").where("c..).queryOne()

[MSG]The String 'communicationEventId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]communicationEvent.communicationEventTypeId = "EMAIL_COMMUNICATION"

[MSG]The String 'EMAIL_COMMUNICATION' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]communicationEvent.contactMechTypeId = "EMAIL_ADDRESS"

[MSG]The String 'EMAIL_ADDRESS' can be wrapped in single quotes instead of double quotes

SpaceAfterComma338

[SRC]checkOwner = from("ProductRole").where("productId", prod...queryList()

[MSG]The parameter partyId in the call to method where within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma338

[SRC]checkOwner = from("ProductRole").where("productId", prod...queryList()

[MSG]The parameter roleTypeId in the call to method where within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString338

[SRC]checkOwner = from("ProductRole").where("productId", prod...queryList()

[MSG]The String 'ProductRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]checkOwner = from("ProductRole").where("productId", prod...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]checkOwner = from("ProductRole").where("productId", prod...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]checkOwner = from("ProductRole").where("productId", prod...queryList()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]checkOwner = from("ProductRole").where("productId", prod...queryList()

[MSG]The String 'PRODUCT_OWNER' can be wrapped in single quotes instead of double quotes

TrailingWhitespace341

[SRC]

[MSG]Line ends with whitespace characters

SpaceAfterComma343

[SRC]productRole = from("ProductRole").where("productId", pro...queryList()

[MSG]The parameter roleTypeId in the call to method where within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString343

[SRC]productRole = from("ProductRole").where("productId", pro...queryList()

[MSG]The String 'ProductRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]productRole = from("ProductRole").where("productId", pro...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]productRole = from("ProductRole").where("productId", pro...queryList()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]productRole = from("ProductRole").where("productId", pro...queryList()

[MSG]The String 'PRODUCT_OWNER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString345

[SRC]parentCom = from("CommunicationEvent").where("communicat..).queryOne()

[MSG]The String 'CommunicationEvent' can be wrapped in single quotes instead of double quotes

UnnecessaryGString345

[SRC]parentCom = from("CommunicationEvent").where("communicat..).queryOne()

[MSG]The String 'communicationEventId' can be wrapped in single quotes instead of double quotes

SpaceAroundMapEntryColon351

[SRC]resultsIdFrom = runService('getPartyEmail', ["partyId" :.. userLogin])

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon351

[SRC]resultsIdFrom = runService('getPartyEmail', ["partyId" :.. userLogin])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString351

[SRC]resultsIdFrom = runService('getPartyEmail', ["partyId" :.. userLogin])

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString351

[SRC]resultsIdFrom = runService('getPartyEmail', ["partyId" :.. userLogin])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

SpaceAfterComma358

[SRC]resultsIdTo = runService('getPartyEmail', ["partyId" : d.. userLogin])

[MSG]The map entry contactMechPurposeTypeId:SUPPORT_EMAIL within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundMapEntryColon358

[SRC]resultsIdTo = runService('getPartyEmail', ["partyId" : d.. userLogin])

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon358

[SRC]resultsIdTo = runService('getPartyEmail', ["partyId" : d.. userLogin])

[MSG]The colon for the literal Map entry for key [contactMechPurposeTypeId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon358

[SRC]resultsIdTo = runService('getPartyEmail', ["partyId" : d.. userLogin])

[MSG]The colon for the literal Map entry for key [contactMechPurposeTypeId] within class org.apache.ofbiz.scrum.None is not followed by a match for regular expression [\s]

SpaceAroundMapEntryColon358

[SRC]resultsIdTo = runService('getPartyEmail', ["partyId" : d.. userLogin])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString358

[SRC]resultsIdTo = runService('getPartyEmail', ["partyId" : d.. userLogin])

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString358

[SRC]resultsIdTo = runService('getPartyEmail', ["partyId" : d.. userLogin])

[MSG]The String 'contactMechPurposeTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString358

[SRC]resultsIdTo = runService('getPartyEmail', ["partyId" : d.. userLogin])

[MSG]The String 'SUPPORT_EMAIL' can be wrapped in single quotes instead of double quotes

UnnecessaryGString358

[SRC]resultsIdTo = runService('getPartyEmail', ["partyId" : d.. userLogin])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

TrailingWhitespace368

[SRC]

[MSG]Line ends with whitespace characters

SpaceAfterComma372

[SRC]resultsIdFrom = runService('getPartyEmail', ["partyId" :.. userLogin])

[MSG]The map entry contactMechPurposeTypeId:SUPPORT_EMAIL within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundMapEntryColon372

[SRC]resultsIdFrom = runService('getPartyEmail', ["partyId" :.. userLogin])

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon372

[SRC]resultsIdFrom = runService('getPartyEmail', ["partyId" :.. userLogin])

[MSG]The colon for the literal Map entry for key [contactMechPurposeTypeId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon372

[SRC]resultsIdFrom = runService('getPartyEmail', ["partyId" :.. userLogin])

[MSG]The colon for the literal Map entry for key [contactMechPurposeTypeId] within class org.apache.ofbiz.scrum.None is not followed by a match for regular expression [\s]

SpaceAroundMapEntryColon372

[SRC]resultsIdFrom = runService('getPartyEmail', ["partyId" :.. userLogin])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString372

[SRC]resultsIdFrom = runService('getPartyEmail', ["partyId" :.. userLogin])

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString372

[SRC]resultsIdFrom = runService('getPartyEmail', ["partyId" :.. userLogin])

[MSG]The String 'contactMechPurposeTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString372

[SRC]resultsIdFrom = runService('getPartyEmail', ["partyId" :.. userLogin])

[MSG]The String 'SUPPORT_EMAIL' can be wrapped in single quotes instead of double quotes

UnnecessaryGString372

[SRC]resultsIdFrom = runService('getPartyEmail', ["partyId" :.. userLogin])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

SpaceAfterComma378

[SRC]productRole = from("ProductRole").where("productId", pro...queryList()

[MSG]The parameter roleTypeId in the call to method where within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString378

[SRC]productRole = from("ProductRole").where("productId", pro...queryList()

[MSG]The String 'ProductRole' can be wrapped in single quotes instead of double quotes

UnnecessaryGString378

[SRC]productRole = from("ProductRole").where("productId", pro...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString378

[SRC]productRole = from("ProductRole").where("productId", pro...queryList()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString378

[SRC]productRole = from("ProductRole").where("productId", pro...queryList()

[MSG]The String 'PRODUCT_OWNER' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]parentCom = from("CommunicationEvent").where("communicat..).queryOne()

[MSG]The String 'CommunicationEvent' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]parentCom = from("CommunicationEvent").where("communicat..).queryOne()

[MSG]The String 'communicationEventId' can be wrapped in single quotes instead of double quotes

SpaceAfterIf381

[SRC]if(parentCom){

[MSG]The if keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace381

[SRC]if(parentCom){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

Indentation384

[SRC]context.partyIdTo = parentCom.partyIdFrom

[MSG]The statement on line 84 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 17 but was 18

Indentation386

[SRC]resultsIdTo = runService('getPartyEmail', ["partyId" : p.. userLogin])

[MSG]The statement on line 86 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 12

SpaceAroundMapEntryColon386

[SRC]resultsIdTo = runService('getPartyEmail', ["partyId" : p.. userLogin])

[MSG]The colon for the literal Map entry for key [partyId] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

SpaceAroundMapEntryColon386

[SRC]resultsIdTo = runService('getPartyEmail', ["partyId" : p.. userLogin])

[MSG]The colon for the literal Map entry for key [userLogin] within class org.apache.ofbiz.scrum.None is not preceded by a match for regular expression [\S]

UnnecessaryGString386

[SRC]resultsIdTo = runService('getPartyEmail', ["partyId" : p.. userLogin])

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString386

[SRC]resultsIdTo = runService('getPartyEmail', ["partyId" : p.. userLogin])

[MSG]The String 'userLogin' can be wrapped in single quotes instead of double quotes

Indentation387

[SRC]if (resultsIdTo.contactMechId != null) {

[MSG]The statement on line 87 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 12

Indentation388

[SRC]context.contactMechIdTo = resultsIdTo.contactMechId

[MSG]The statement on line 88 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 17 but was 15

Indentation389

[SRC]communicationEvent.contactMechIdTo = resultsIdTo.contactMechId

[MSG]The statement on line 89 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 17 but was 15

Indentation391

[SRC]communicationEvent.store()

[MSG]The statement on line 91 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 12

Indentation392

[SRC]context.communicationEvent = communicationEvent

[MSG]The statement on line 92 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 13 but was 12

UnnecessaryGString396

[SRC]logInfo("catch exeption ================" + exeption)

[MSG]The String 'catch exeption ================' can be wrapped in single quotes instead of double quotes

UnnecessaryGString398

[SRC]logInfo("catch GenericEntityException ================" ..etMessage())

[MSG]The String 'catch GenericEntityException ================' can be wrapped in single quotes instead of double quotes

➥ QuickAddBacklog.groovy

Rule NamePriorityLine #Source Line / Message
SpaceAfterClosingBrace321

[SRC]try{

[MSG]The closing brace for the block in class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceBeforeOpeningBrace321

[SRC]try{

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma324

[SRC]sprintList = from("WorkEffort").where("workEffortTypeId"...queryList()

[MSG]The parameter currentStatusId in the call to method where within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString324

[SRC]sprintList = from("WorkEffort").where("workEffortTypeId"...queryList()

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString324

[SRC]sprintList = from("WorkEffort").where("workEffortTypeId"...queryList()

[MSG]The String 'workEffortTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString324

[SRC]sprintList = from("WorkEffort").where("workEffortTypeId"...queryList()

[MSG]The String 'SCRUM_SPRINT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString324

[SRC]sprintList = from("WorkEffort").where("workEffortTypeId"...queryList()

[MSG]The String 'currentStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString324

[SRC]sprintList = from("WorkEffort").where("workEffortTypeId"...queryList()

[MSG]The String 'SPRINT_ACTIVE' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace326

[SRC]sprintList.each{ sprintMap ->

[MSG]The opening brace for the closure in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

Indentation330

[SRC]projectList = from("WorkEffortAndProduct").where("workEf...queryList()

[MSG]The statement on line 30 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

UnnecessaryGString330

[SRC]projectList = from("WorkEffortAndProduct").where("workEf...queryList()

[MSG]The String 'WorkEffortAndProduct' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]projectList = from("WorkEffortAndProduct").where("workEf...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

Indentation331

[SRC]projectMap = projectList[0]

[MSG]The statement on line 31 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

Indentation333

[SRC]if ("SPJ_CLOSED" != projectMap.currentStatusId) {

[MSG]The statement on line 33 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

UnnecessaryGString333

[SRC]if ("SPJ_CLOSED" != projectMap.currentStatusId) {

[MSG]The String 'SPJ_CLOSED' can be wrapped in single quotes instead of double quotes

Indentation334

[SRC]productMap = from("Product").where("productId", projectM..).queryOne()

[MSG]The statement on line 34 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

UnnecessaryGString334

[SRC]productMap = from("Product").where("productId", projectM..).queryOne()

[MSG]The String 'Product' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]productMap = from("Product").where("productId", projectM..).queryOne()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

Indentation335

[SRC]workEffortMap.productId = productMap.productId

[MSG]The statement on line 35 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

Indentation336

[SRC]workEffortMap.internalName = returnNameAsString(productM..rnalName,30)

[MSG]The statement on line 36 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

SpaceAfterComma336

[SRC]workEffortMap.internalName = returnNameAsString(productM..rnalName,30)

[MSG]The parameter 30 in the call to method returnNameAsString within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

Indentation337

[SRC]workEffortMap.projectId = projectMap.workEffortId

[MSG]The statement on line 37 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

Indentation338

[SRC]workEffortMap.projectName = returnNameAsString(projectMa..fortName,30)

[MSG]The statement on line 38 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

SpaceAfterComma338

[SRC]workEffortMap.projectName = returnNameAsString(projectMa..fortName,30)

[MSG]The parameter 30 in the call to method returnNameAsString within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

Indentation339

[SRC]workEffortMap.sprintId = sprintMap.workEffortId

[MSG]The statement on line 39 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

Indentation340

[SRC]workEffortMap.sprintName = returnNameAsString(sprintMap...fortName,30)

[MSG]The statement on line 40 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

SpaceAfterComma340

[SRC]workEffortMap.sprintName = returnNameAsString(sprintMap...fortName,30)

[MSG]The parameter 30 in the call to method returnNameAsString within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

Indentation341

[SRC]workEffortMap.keyId = productMap.productId+","+projectMa..workEffortId

[MSG]The statement on line 41 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

SpaceAroundOperator341

[SRC]workEffortMap.keyId = productMap.productId+","+projectMa..workEffortId

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator341

[SRC]workEffortMap.keyId = productMap.productId+","+projectMa..workEffortId

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator341

[SRC]workEffortMap.keyId = productMap.productId+","+projectMa..workEffortId

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator341

[SRC]workEffortMap.keyId = productMap.productId+","+projectMa..workEffortId

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator341

[SRC]workEffortMap.keyId = productMap.productId+","+projectMa..workEffortId

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator341

[SRC]workEffortMap.keyId = productMap.productId+","+projectMa..workEffortId

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

SpaceAroundOperator341

[SRC]workEffortMap.keyId = productMap.productId+","+projectMa..workEffortId

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator341

[SRC]workEffortMap.keyId = productMap.productId+","+projectMa..workEffortId

[MSG]The operator "+" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

UnnecessaryGString341

[SRC]workEffortMap.keyId = productMap.productId+","+projectMa..workEffortId

[MSG]The String ',' can be wrapped in single quotes instead of double quotes

UnnecessaryGString341

[SRC]workEffortMap.keyId = productMap.productId+","+projectMa..workEffortId

[MSG]The String ',' can be wrapped in single quotes instead of double quotes

Indentation342

[SRC]workEffortList.add(workEffortMap)

[MSG]The statement on line 42 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [21, 25, 29] but was 20

UnnecessaryGString355

[SRC]indexList = parameters.keyId.tokenize(",")

[MSG]The String ',' can be wrapped in single quotes instead of double quotes

SpaceAfterComma361

[SRC]sprintList = from("CustRequestAndCustRequestItem").where...queryList()

[MSG]The parameter productId in the call to method where within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString361

[SRC]sprintList = from("CustRequestAndCustRequestItem").where...queryList()

[MSG]The String 'CustRequestAndCustRequestItem' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]sprintList = from("CustRequestAndCustRequestItem").where...queryList()

[MSG]The String 'custRequestTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]sprintList = from("CustRequestAndCustRequestItem").where...queryList()

[MSG]The String 'RF_PARENT_BACKLOG' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]sprintList = from("CustRequestAndCustRequestItem").where...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]sprintList = from("CustRequestAndCustRequestItem").where...queryList()

[MSG]The String 'CustRequestAndCustRequestItem' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]sprintList = from("CustRequestAndCustRequestItem").where...queryList()

[MSG]The String 'custRequestTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]sprintList = from("CustRequestAndCustRequestItem").where...queryList()

[MSG]The String 'RF_PARENT_BACKLOG' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace366

[SRC]sprintList.each{ categoryMap ->

[MSG]The opening brace for the closure in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

Indentation370

[SRC]productMap = from("Product").where("productId", productI..).queryOne()

[MSG]The statement on line 70 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

UnnecessaryGString370

[SRC]productMap = from("Product").where("productId", productI..).queryOne()

[MSG]The String 'Product' can be wrapped in single quotes instead of double quotes

UnnecessaryGString370

[SRC]productMap = from("Product").where("productId", productI..).queryOne()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

Indentation371

[SRC]inputMap.productId = productMap.productId

[MSG]The statement on line 71 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

Indentation372

[SRC]inputMap.internalName = productMap.internalName

[MSG]The statement on line 72 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

Indentation373

[SRC]inputMap.custRequestId = categoryMap.custRequestId

[MSG]The statement on line 73 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

Indentation374

[SRC]inputMap.custRequestName = categoryMap.custRequestName

[MSG]The statement on line 74 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

Indentation375

[SRC]categoryList.add(inputMap)

[MSG]The statement on line 75 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected one of columns [17, 21, 25] but was 16

SpaceAfterCatch380

[SRC]}catch(e){

[MSG]The catch keyword within class org.apache.ofbiz.scrum.None is not followed by a single space

SpaceBeforeOpeningBrace380

[SRC]}catch(e){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString381

[SRC]logInfo("catch e ================" + e)

[MSG]The String 'catch e ================' can be wrapped in single quotes instead of double quotes

MethodParameterTypeRequired385

[SRC]def String returnNameAsString(input,length) {

[MSG]"input" parameter of "returnNameAsString" method is dynamically typed

MethodParameterTypeRequired385

[SRC]def String returnNameAsString(input,length) {

[MSG]"length" parameter of "returnNameAsString" method is dynamically typed

NoDef385

[SRC]def String returnNameAsString(input,length) {

[MSG]def for method parameter type should not be used

NoDef385

[SRC]def String returnNameAsString(input,length) {

[MSG]def for method parameter type should not be used

SpaceAfterComma385

[SRC]def String returnNameAsString(input,length) {

[MSG]The parameter length of method returnNameAsString within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryDefInMethodDeclaration385

[SRC]def String returnNameAsString(input,length) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. The def keyword is unneeded when a method specifies a return type

Indentation386

[SRC]if (input.length() > length ) {

[MSG]The statement on line 86 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 2

Indentation387

[SRC]ansValue = input.toString().substring(0,Math.min(input.t..h(),length))

[MSG]The statement on line 87 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 6

SpaceAfterComma387

[SRC]ansValue = input.toString().substring(0,Math.min(input.t..h(),length))

[MSG]The parameter Math.min(input.toString().length(), length) in the call to method substring within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma387

[SRC]ansValue = input.toString().substring(0,Math.min(input.t..h(),length))

[MSG]The parameter length in the call to method min within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

Indentation388

[SRC]return ansValue

[MSG]The statement on line 88 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 6

UnnecessaryElseStatement389

[SRC]} else {

[MSG]When an if statement block ends with a return statement the else is unnecessary

Indentation390

[SRC]return input

[MSG]The statement on line 90 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 9 but was 6

➥ SprintBacklogListItems.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod230

[SRC]if ("SPRINT_CLOSED".equals(currentStatus)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to SPRINT_CLOSED.equals(currentStatus) method can be rewritten as (SPRINT_CLOSED == (currentStatus))

ExplicitCallToEqualsMethod286

[SRC]if ("CRQ_REVIEWED".equals(custMap.statusId)){

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to CRQ_REVIEWED.equals(custMap.statusId) method can be rewritten as (CRQ_REVIEWED == (custMap.statusId))

ExplicitCallToEqualsMethod2105

[SRC]if (!"SCRUM_SPRINT".equals(workEffMap.workEffortTypeId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to SCRUM_SPRINT.equals(workEffMap.workEffortTypeId) method can be rewritten as (SCRUM_SPRINT == (workEffMap.workEffortTypeId))

ExplicitCallToEqualsMethod2107

[SRC]if ("STS_CREATED".equals(workEffMap.currentStatusId)){

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to STS_CREATED.equals(workEffMap.currentStatusId) method can be rewritten as (STS_CREATED == (workEffMap.currentStatusId))

UnnecessaryGString330

[SRC]if ("SPRINT_CLOSED".equals(currentStatus)) {

[MSG]The String 'SPRINT_CLOSED' can be wrapped in single quotes instead of double quotes

InvertedCondition333

[SRC]if ("Any" == backlogStatusId) {

[MSG]Any is a constant expression on the left side of a compare equals operation

UnnecessaryGString333

[SRC]if ("Any" == backlogStatusId) {

[MSG]The String 'Any' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]backlogStatusId = "CRQ_REVIEWED"

[MSG]The String 'CRQ_REVIEWED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]reopenedStatusId = "CRQ_REOPENED"

[MSG]The String 'CRQ_REOPENED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]taskStatusId = "STS_CREATED"

[MSG]The String 'STS_CREATED' can be wrapped in single quotes instead of double quotes

Indentation343

[SRC]orCurentExprs.add(EntityCondition.makeCondition("taskCur..skStatusId))

[MSG]The statement on line 43 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

UnnecessaryGString343

[SRC]orCurentExprs.add(EntityCondition.makeCondition("taskCur..skStatusId))

[MSG]The String 'taskCurrentStatusId' can be wrapped in single quotes instead of double quotes

Indentation344

[SRC]orCurentExprs.add(EntityCondition.makeCondition("taskCur..NT_ACTIVE"))

[MSG]The statement on line 44 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

UnnecessaryGString344

[SRC]orCurentExprs.add(EntityCondition.makeCondition("taskCur..NT_ACTIVE"))

[MSG]The String 'taskCurrentStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]orCurentExprs.add(EntityCondition.makeCondition("taskCur..NT_ACTIVE"))

[MSG]The String 'SPRINT_ACTIVE' can be wrapped in single quotes instead of double quotes

Indentation348

[SRC]orBacklogExprs.add(EntityCondition.makeCondition("backlo..ogStatusId))

[MSG]The statement on line 48 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

UnnecessaryGString348

[SRC]orBacklogExprs.add(EntityCondition.makeCondition("backlo..ogStatusId))

[MSG]The String 'backlogStatusId' can be wrapped in single quotes instead of double quotes

Indentation351

[SRC]orBacklogExprs.add(EntityCondition.makeCondition("backlo..edStatusId))

[MSG]The statement on line 51 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

UnnecessaryGString351

[SRC]orBacklogExprs.add(EntityCondition.makeCondition("backlo..edStatusId))

[MSG]The String 'backlogStatusId' can be wrapped in single quotes instead of double quotes

Indentation355

[SRC]andExprs.add(EntityCondition.makeCondition("projectId", ...projectId))

[MSG]The statement on line 55 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

UnnecessaryGString355

[SRC]andExprs.add(EntityCondition.makeCondition("projectId", ...projectId))

[MSG]The String 'projectId' can be wrapped in single quotes instead of double quotes

Indentation357

[SRC]andExprs.add(EntityCondition.makeCondition("projectId", ..rtParentId))

[MSG]The statement on line 57 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

UnnecessaryGString357

[SRC]andExprs.add(EntityCondition.makeCondition("projectId", ..rtParentId))

[MSG]The String 'projectId' can be wrapped in single quotes instead of double quotes

Indentation360

[SRC]andExprs.add(EntityCondition.makeCondition(orBacklogExpr..perator.OR))

[MSG]The statement on line 60 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

Indentation363

[SRC]andExprs.add(EntityCondition.makeCondition(orCurentExprs..perator.OR))

[MSG]The statement on line 63 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 9

UnnecessaryGString365

[SRC]andExprs.add(EntityCondition.makeCondition("sprintId", E..s.sprintId))

[MSG]The String 'sprintId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString366

[SRC]andExprs.add(EntityCondition.makeCondition("sprintTypeId..UM_SPRINT"))

[MSG]The String 'sprintTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString366

[SRC]andExprs.add(EntityCondition.makeCondition("sprintTypeId..UM_SPRINT"))

[MSG]The String 'SCRUM_SPRINT' can be wrapped in single quotes instead of double quotes

TrailingWhitespace367

[SRC]

[MSG]Line ends with whitespace characters

SpaceAfterComma369

[SRC]projectSprintList = from("ProjectSprintBacklogAndTask")....queryList()

[MSG]The parameter custRequestId in the call to method orderBy within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma369

[SRC]projectSprintList = from("ProjectSprintBacklogAndTask")....queryList()

[MSG]The parameter taskTypeId in the call to method orderBy within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString369

[SRC]projectSprintList = from("ProjectSprintBacklogAndTask")....queryList()

[MSG]The String 'ProjectSprintBacklogAndTask' can be wrapped in single quotes instead of double quotes

UnnecessaryGString369

[SRC]projectSprintList = from("ProjectSprintBacklogAndTask")....queryList()

[MSG]The String 'custSequenceNum' can be wrapped in single quotes instead of double quotes

UnnecessaryGString369

[SRC]projectSprintList = from("ProjectSprintBacklogAndTask")....queryList()

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString369

[SRC]projectSprintList = from("ProjectSprintBacklogAndTask")....queryList()

[MSG]The String 'taskTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString381

[SRC]sprintList = from("CustRequestWorkEffort").where("workEf...queryList()

[MSG]The String 'CustRequestWorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString381

[SRC]sprintList = from("CustRequestWorkEffort").where("workEf...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString383

[SRC]custMap = sprintMap.getRelatedOne("CustRequest", false)

[MSG]The String 'CustRequest' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace386

[SRC]if ("CRQ_REVIEWED".equals(custMap.statusId)){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString386

[SRC]if ("CRQ_REVIEWED".equals(custMap.statusId)){

[MSG]The String 'CRQ_REVIEWED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString392

[SRC]workEffortList = custMap.getRelated("CustRequestWorkEffo..null, false)

[MSG]The String 'CustRequestWorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3104

[SRC]workEffMap = taskMap.getRelatedOne("WorkEffort", false)

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString3105

[SRC]if (!"SCRUM_SPRINT".equals(workEffMap.workEffortTypeId)) {

[MSG]The String 'SCRUM_SPRINT' can be wrapped in single quotes instead of double quotes

SpaceBeforeOpeningBrace3107

[SRC]if ("STS_CREATED".equals(workEffMap.currentStatusId)){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString3107

[SRC]if ("STS_CREATED".equals(workEffMap.currentStatusId)){

[MSG]The String 'STS_CREATED' can be wrapped in single quotes instead of double quotes

➥ SprintBacklogOptions.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod227

[SRC]if ("SCRUM_SPRINT".equals(workEffortMap.workEffortTypeId..StatusId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to SCRUM_SPRINT.equals(workEffortMap.workEffortTypeId) method can be rewritten as (SCRUM_SPRINT == (workEffortMap.workEffortTypeId))

ExplicitCallToEqualsMethod227

[SRC]if ("SCRUM_SPRINT".equals(workEffortMap.workEffortTypeId..StatusId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to SPRINT_ACTIVE.equals(workEffortMap.currentStatusId) method can be rewritten as (SPRINT_ACTIVE == (workEffortMap.currentStatusId))

UnnecessaryGString321

[SRC]sprintStatusId = "SPRINT_CLOSED"

[MSG]The String 'SPRINT_CLOSED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString323

[SRC]custRequestWorkEffortList = custRequestMap.getRelated("C..null, false)

[MSG]The String 'CustRequestWorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString326

[SRC]workEffortMap = custWorkEffortMap.getRelatedOne("WorkEffort", false)

[MSG]The String 'WorkEffort' can be wrapped in single quotes instead of double quotes

UnnecessaryGString327

[SRC]if ("SCRUM_SPRINT".equals(workEffortMap.workEffortTypeId..StatusId)) {

[MSG]The String 'SCRUM_SPRINT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString327

[SRC]if ("SCRUM_SPRINT".equals(workEffortMap.workEffortTypeId..StatusId)) {

[MSG]The String 'SPRINT_ACTIVE' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]sprintStatusId = "SPRINT_ACTIVE"

[MSG]The String 'SPRINT_ACTIVE' can be wrapped in single quotes instead of double quotes

TrailingWhitespace330

[SRC]}

[MSG]Line ends with whitespace characters

BlockEndsWithBlankLine332

[MSG]Code block ends with a blank line.

TrailingWhitespace332

[SRC]

[MSG]Line ends with whitespace characters

➥ TaskList.groovy

Rule NamePriorityLine #Source Line / Message
LineLength228

[SRC]//${projectId} - ${projectName} - ${sprintName} - ${groo..{taskId}]"/>

[MSG]The line exceeds 150 characters. The line is 215 characters.

LineLength230

[SRC]taskUnplanList = from("ProjectSprintBacklogTaskAndParty"...queryList()

[MSG]The line exceeds 150 characters. The line is 194 characters.

ExplicitCallToEqualsMethod267

[SRC]if ("RF_SCRUM_MEETINGS".equals(taskPlanMap.custRequestTypeId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to RF_SCRUM_MEETINGS.equals(taskPlanMap.custRequestTypeId) method can be rewritten as (RF_SCRUM_MEETINGS == (taskPlanMap.custRequestTypeId))

ExplicitCallToEqualsMethod270

[SRC]if (!"SCAS_COMPLETED".equals(workEffPartyAssignedMap.statusId)) {

[MSG]Violation in class org.apache.ofbiz.scrum.None. Explicit call to SCAS_COMPLETED.equals(workEffPartyAssignedMap.statusId) method can be rewritten as (SCAS_COMPLETED == (workEffPartyAssignedMap.statusId))

SpaceAfterComma330

[SRC]taskUnplanList = from("ProjectSprintBacklogTaskAndParty"...queryList()

[MSG]The parameter taskCurrentStatusId in the call to method where within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma330

[SRC]taskUnplanList = from("ProjectSprintBacklogTaskAndParty"...queryList()

[MSG]The parameter custRequestTypeId in the call to method where within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma330

[SRC]taskUnplanList = from("ProjectSprintBacklogTaskAndParty"...queryList()

[MSG]The parameter RF_UNPLAN_BACKLOG in the call to method where within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString330

[SRC]taskUnplanList = from("ProjectSprintBacklogTaskAndParty"...queryList()

[MSG]The String 'ProjectSprintBacklogTaskAndParty' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]taskUnplanList = from("ProjectSprintBacklogTaskAndParty"...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]taskUnplanList = from("ProjectSprintBacklogTaskAndParty"...queryList()

[MSG]The String 'taskCurrentStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]taskUnplanList = from("ProjectSprintBacklogTaskAndParty"...queryList()

[MSG]The String 'STS_CREATED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]taskUnplanList = from("ProjectSprintBacklogTaskAndParty"...queryList()

[MSG]The String 'custRequestTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]taskUnplanList = from("ProjectSprintBacklogTaskAndParty"...queryList()

[MSG]The String 'RF_UNPLAN_BACKLOG' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]taskUnplanList = from("ProjectSprintBacklogTaskAndParty"...queryList()

[MSG]The String 'taskTypeId' can be wrapped in single quotes instead of double quotes

NoTabCharacter332

[MSG]The tab character is not allowed in source files

Indentation332

[SRC]unplanMap=[:]

[MSG]The statement on line 32 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [5, 9, 13] or one of [19, 23, 27] columns, but was 2

SpaceAroundOperator332

[SRC]unplanMap=[:]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator332

[SRC]unplanMap=[:]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

Indentation333

[SRC]custRequestId = taskUnplanMap.custRequestId

[MSG]The statement on line 33 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [5, 9, 13] or one of [19, 23, 27] columns, but was 2

Indentation334

[SRC]productlist = from("CustRequestItem").where("custRequest...queryList()

[MSG]The statement on line 34 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [5, 9, 13] or one of [19, 23, 27] columns, but was 2

UnnecessaryGString334

[SRC]productlist = from("CustRequestItem").where("custRequest...queryList()

[MSG]The String 'CustRequestItem' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]productlist = from("CustRequestItem").where("custRequest...queryList()

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]productlist = from("CustRequestItem").where("custRequest...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

Indentation335

[SRC]productlist.each { productMap ->

[MSG]The statement on line 35 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [5, 9, 13] or one of [19, 23, 27] columns, but was 2

Indentation336

[SRC]productId = productMap.productId

[MSG]The statement on line 36 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [9, 13, 17] or one of [17, 21, 25] columns, but was 3

Indentation337

[SRC]product = from("Product").where("productId", productId).queryOne()

[MSG]The statement on line 37 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [9, 13, 17] or one of [17, 21, 25] columns, but was 3

UnnecessaryGString337

[SRC]product = from("Product").where("productId", productId).queryOne()

[MSG]The String 'Product' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]product = from("Product").where("productId", productId).queryOne()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

Indentation338

[SRC]productName = product.internalName

[MSG]The statement on line 38 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [9, 13, 17] or one of [17, 21, 25] columns, but was 4

Indentation339

[SRC]unplanMap.taskId = taskUnplanMap.taskId

[MSG]The statement on line 39 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [9, 13, 17] or one of [17, 21, 25] columns, but was 4

Indentation340

[SRC]unplanMap.taskName = taskUnplanMap.taskName

[MSG]The statement on line 40 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [9, 13, 17] or one of [17, 21, 25] columns, but was 4

Indentation341

[SRC]unplanMap.projectId = taskUnplanMap.projectId

[MSG]The statement on line 41 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [9, 13, 17] or one of [17, 21, 25] columns, but was 4

Indentation342

[SRC]unplanMap.projectName = taskUnplanMap.projectName

[MSG]The statement on line 42 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [9, 13, 17] or one of [17, 21, 25] columns, but was 4

Indentation343

[SRC]unplanMap.sprintId = taskUnplanMap.sprintId

[MSG]The statement on line 43 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [9, 13, 17] or one of [17, 21, 25] columns, but was 4

Indentation344

[SRC]unplanMap.sprintName = taskUnplanMap.sprintName

[MSG]The statement on line 44 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [9, 13, 17] or one of [17, 21, 25] columns, but was 4

Indentation345

[SRC]unplanMap.custRequestId = custRequestId

[MSG]The statement on line 45 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [9, 13, 17] or one of [17, 21, 25] columns, but was 4

Indentation346

[SRC]unplanMap.description = taskUnplanMap.description

[MSG]The statement on line 46 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [9, 13, 17] or one of [17, 21, 25] columns, but was 4

Indentation347

[SRC]unplanMap.productId = productId

[MSG]The statement on line 47 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [9, 13, 17] or one of [17, 21, 25] columns, but was 4

UnnecessaryObjectReferences347

[SRC]unplanMap.productId = productId

[MSG]The code could be more concise by using a with() or identity() block

Indentation348

[SRC]unplanMap.productName = productName

[MSG]The statement on line 48 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [9, 13, 17] or one of [17, 21, 25] columns, but was 4

UnnecessaryObjectReferences348

[SRC]unplanMap.productName = productName

[MSG]The code could be more concise by using a with() or identity() block

BlockEndsWithBlankLine349

[MSG]Code block ends with a blank line.

TrailingWhitespace349

[SRC]

[MSG]Line ends with whitespace characters

Indentation351

[SRC]taskPartyList.add(taskUnplanMap)

[MSG]The statement on line 51 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [5, 9, 13] or one of [19, 23, 27] columns, but was 2

Indentation352

[SRC]taskListDropdown.add(unplanMap)

[MSG]The statement on line 52 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Depending on your chaining style, expected one of [5, 9, 13] or one of [19, 23, 27] columns, but was 2

UnnecessaryGString356

[SRC]exprBldr.add(EntityCondition.makeCondition("custRequestT..D_BACKLOG"))

[MSG]The String 'custRequestTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString356

[SRC]exprBldr.add(EntityCondition.makeCondition("custRequestT..D_BACKLOG"))

[MSG]The String 'RF_PROD_BACKLOG' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]exprBldr.add(EntityCondition.makeCondition("custRequestT.._MEETINGS"))

[MSG]The String 'custRequestTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString357

[SRC]exprBldr.add(EntityCondition.makeCondition("custRequestT.._MEETINGS"))

[MSG]The String 'RF_SCRUM_MEETINGS' can be wrapped in single quotes instead of double quotes

UnnecessaryGString359

[SRC]andExprs.add(EntityCondition.makeCondition("taskCurrentS..S_CREATED"))

[MSG]The String 'taskCurrentStatusId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString359

[SRC]andExprs.add(EntityCondition.makeCondition("taskCurrentS..S_CREATED"))

[MSG]The String 'STS_CREATED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString360

[SRC]andExprs.add(EntityCondition.makeCondition("partyId", En..S, partyId))

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

SpaceAfterComma364

[SRC]taskPlanList = from("ProjectSprintBacklogTaskAndParty")....queryList()

[MSG]The parameter projectId in the call to method orderBy within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAfterComma364

[SRC]taskPlanList = from("ProjectSprintBacklogTaskAndParty")....queryList()

[MSG]The parameter sprintId in the call to method orderBy within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

UnnecessaryGString364

[SRC]taskPlanList = from("ProjectSprintBacklogTaskAndParty")....queryList()

[MSG]The String 'ProjectSprintBacklogTaskAndParty' can be wrapped in single quotes instead of double quotes

UnnecessaryGString364

[SRC]taskPlanList = from("ProjectSprintBacklogTaskAndParty")....queryList()

[MSG]The String 'taskTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString364

[SRC]taskPlanList = from("ProjectSprintBacklogTaskAndParty")....queryList()

[MSG]The String 'projectId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString364

[SRC]taskPlanList = from("ProjectSprintBacklogTaskAndParty")....queryList()

[MSG]The String 'sprintId' can be wrapped in single quotes instead of double quotes

SpaceAroundOperator366

[SRC]planMap=[:]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

SpaceAroundOperator366

[SRC]planMap=[:]

[MSG]The operator "=" within class org.apache.ofbiz.scrum.None is not followed by a space or whitespace

UnnecessaryGString367

[SRC]if ("RF_SCRUM_MEETINGS".equals(taskPlanMap.custRequestTypeId)) {

[MSG]The String 'RF_SCRUM_MEETINGS' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]workEffPartyAssignedList = from("WorkEffortPartyAssignme...queryList()

[MSG]The String 'WorkEffortPartyAssignment' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]workEffPartyAssignedList = from("WorkEffortPartyAssignme...queryList()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString368

[SRC]workEffPartyAssignedList = from("WorkEffortPartyAssignme...queryList()

[MSG]The String 'workEffortId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString370

[SRC]if (!"SCAS_COMPLETED".equals(workEffPartyAssignedMap.statusId)) {

[MSG]The String 'SCAS_COMPLETED' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]productlist = from("CustRequestItem").where("custRequest...queryList()

[MSG]The String 'CustRequestItem' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]productlist = from("CustRequestItem").where("custRequest...queryList()

[MSG]The String 'custRequestId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString380

[SRC]productlist = from("CustRequestItem").where("custRequest...queryList()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString381

[SRC]product = from("Product").where("productId", productlist..).queryOne()

[MSG]The String 'Product' can be wrapped in single quotes instead of double quotes

UnnecessaryGString381

[SRC]product = from("Product").where("productId", productlist..).queryOne()

[MSG]The String 'productId' can be wrapped in single quotes instead of double quotes

UnnecessaryObjectReferences391

[SRC]planMap.description = taskPlanMap.description

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences392

[SRC]planMap.productId = productlist[0].productId

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryObjectReferences393

[SRC]planMap.productName = productName

[MSG]The code could be more concise by using a with() or identity() block

BlockEndsWithBlankLine397

[MSG]Code block ends with a blank line.

SpaceBeforeOpeningBrace3100

[SRC]if (taskPartyList){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

Indentation3101

[SRC]context.taskPartyList = taskPartyList

[MSG]The statement on line 101 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 2

SpaceBeforeOpeningBrace3103

[SRC]if (taskListDropdown){

[MSG]The opening brace for the block in class org.apache.ofbiz.scrum.None is not preceded by a space or whitespace

Indentation3104

[SRC]context.taskListDropdown = taskListDropdown

[MSG]The statement on line 104 in class org.apache.ofbiz.scrum.None is at the incorrect indent level: Expected column 5 but was 2

Package: org.apache.ofbiz.webpos

➥ Login.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGString324

[SRC]context.autoUserLogin = session.getAttribute("autoUserLogin")

[MSG]The String 'autoUserLogin' can be wrapped in single quotes instead of double quotes

UnnecessaryGString325

[SRC]context.autoLogoutUrl = LoginWorker.makeLoginUrl(request..autoLogout")

[MSG]The String 'autoLogout' can be wrapped in single quotes instead of double quotes

UnnecessaryGString327

[SRC]previousParams = session.getAttribute("_PREVIOUS_PARAMS_")

[MSG]The String '_PREVIOUS_PARAMS_' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]previousParams = "?" + previousParams

[MSG]The String '?' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]previousParams = ""

[MSG]The String '' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]facilityId = productStore.getString("inventoryFacilityId")

[MSG]The String 'inventoryFacilityId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]context.posTerminals = from("PosTerminal").where("facili...queryList()

[MSG]The String 'PosTerminal' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]context.posTerminals = from("PosTerminal").where("facili...queryList()

[MSG]The String 'facilityId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]context.posTerminals = from("PosTerminal").where("facili...queryList()

[MSG]The String 'posTerminalId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString345

[SRC]context.posTerminals = from("PosTerminal").orderBy("posT...queryList()

[MSG]The String 'PosTerminal' can be wrapped in single quotes instead of double quotes

UnnecessaryGString345

[SRC]context.posTerminals = from("PosTerminal").orderBy("posT...queryList()

[MSG]The String 'posTerminalId' can be wrapped in single quotes instead of double quotes

➥ WebPosMenus.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.webpos.WebPosEvents

UnusedImport322

[SRC]import org.apache.ofbiz.webpos.session.WebPosSession

[MSG]The [org.apache.ofbiz.webpos.session.WebPosSession] import is never referenced

UnusedImport323

[SRC]import org.apache.ofbiz.webpos.transaction.WebPosTransaction

[MSG]The [org.apache.ofbiz.webpos.transaction.WebPosTransaction] import is never referenced

➥ WebPosSetup.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGString340

[SRC]globalContext.checkLoginUrl = LoginWorker.makeLoginUrl(r..checkLogin")

[MSG]The String 'checkLogin' can be wrapped in single quotes instead of double quotes

Package: org.apache.ofbiz.webpos.cart

➥ ShowCart.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod261

[SRC]if ("CASH".equals(paymentInfo.paymentMethodTypeId)) {

[MSG]Violation in class org.apache.ofbiz.webpos.cart.None. Explicit call to CASH.equals(paymentInfo.paymentMethodTypeId) method can be rewritten as (CASH == (paymentInfo.paymentMethodTypeId))

ExplicitCallToEqualsMethod264

[SRC]else if ("PERSONAL_CHECK".equals(paymentInfo.paymentMethodTypeId)) {

[MSG]Violation in class org.apache.ofbiz.webpos.cart.None. Explicit call to PERSONAL_CHECK.equals(paymentInfo.paymentMethodTypeId) method can be rewritten as (PERSONAL_CHECK == (paymentInfo.paymentMethodTypeId))

ExplicitCallToEqualsMethod267

[SRC]else if ("GIFT_CARD".equals(paymentInfo.paymentMethodTypeId)) {

[MSG]Violation in class org.apache.ofbiz.webpos.cart.None. Explicit call to GIFT_CARD.equals(paymentInfo.paymentMethodTypeId) method can be rewritten as (GIFT_CARD == (paymentInfo.paymentMethodTypeId))

ExplicitCallToEqualsMethod270

[SRC]else if ("CREDIT_CARD".equals(paymentInfo.paymentMethodTypeId)) {

[MSG]Violation in class org.apache.ofbiz.webpos.cart.None. Explicit call to CREDIT_CARD.equals(paymentInfo.paymentMethodTypeId) method can be rewritten as (CREDIT_CARD == (paymentInfo.paymentMethodTypeId))

UnusedImport321

[SRC]import org.apache.ofbiz.base.util.UtilValidate;

[MSG]The [org.apache.ofbiz.base.util.UtilValidate] import is never referenced

UnnecessarySemicolon321

[SRC]import org.apache.ofbiz.base.util.UtilValidate;

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon322

[SRC]import org.apache.ofbiz.webpos.WebPosEvents;

[MSG]Semicolons as line endings can be removed safely

UnusedImport323

[SRC]import org.apache.ofbiz.webpos.session.WebPosSession;

[MSG]The [org.apache.ofbiz.webpos.session.WebPosSession] import is never referenced

UnnecessarySemicolon323

[SRC]import org.apache.ofbiz.webpos.session.WebPosSession;

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon325

[SRC]webPosSession = WebPosEvents.getWebPosSession(request, null);

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon327

[SRC]shoppingCart = webPosSession.getCart();

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon328

[SRC]context.isManager = webPosSession.isManagerLoggedIn();

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon329

[SRC]context.transactionId = webPosSession.getCurrentTransact..sactionId();

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon330

[SRC]context.userLoginId = webPosSession.getUserLoginId();

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon331

[SRC]context.drawerNumber = webPosSession.getCurrentTransacti..werNumber();

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon332

[SRC]context.totalDue = webPosSession.getCurrentTransaction()..tTotalDue();

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon333

[SRC]context.totalQuantity = webPosSession.getCurrentTransact..lQuantity();

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon334

[SRC]context.isOpen = webPosSession.getCurrentTransaction().isOpen();

[MSG]Semicolons as line endings can be removed safely

TrailingWhitespace335

[SRC]

[MSG]Line ends with whitespace characters

UnnecessarySemicolon336

[SRC]context.person = null;

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString338

[SRC]placingCustomerParty = from("PartyAndPerson").where("par...queryOne();

[MSG]The String 'PartyAndPerson' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]placingCustomerParty = from("PartyAndPerson").where("par...queryOne();

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon338

[SRC]placingCustomerParty = from("PartyAndPerson").where("par...queryOne();

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString340

[SRC]context.person = placingCustomerParty.lastName + " " + p..y.firstName;

[MSG]The String ' ' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon340

[SRC]context.person = placingCustomerParty.lastName + " " + p..y.firstName;

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon344

[SRC]shoppingCart = null;

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon347

[SRC]context.cashAmount = BigDecimal.ZERO;

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon348

[SRC]context.checkAmount = BigDecimal.ZERO;

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon349

[SRC]context.giftAmount = BigDecimal.ZERO;

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon350

[SRC]context.creditAmount = BigDecimal.ZERO;

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon351

[SRC]context.totalPay = BigDecimal.ZERO;

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon354

[SRC]context.shoppingCartSize = shoppingCart.size();

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon355

[SRC]payments = shoppingCart.selectedPayments();

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon357

[SRC]paymentInfo = shoppingCart.getPaymentInfo(i);

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon359

[SRC]amount = paymentInfo.amount;

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString361

[SRC]if ("CASH".equals(paymentInfo.paymentMethodTypeId)) {

[MSG]The String 'CASH' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon362

[SRC]context.cashAmount = new BigDecimal((context.cashAmount).add(amount));

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString364

[SRC]else if ("PERSONAL_CHECK".equals(paymentInfo.paymentMethodTypeId)) {

[MSG]The String 'PERSONAL_CHECK' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon365

[SRC]context.checkAmount = new BigDecimal((context.checkAmoun..dd(amount));

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString367

[SRC]else if ("GIFT_CARD".equals(paymentInfo.paymentMethodTypeId)) {

[MSG]The String 'GIFT_CARD' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon368

[SRC]context.giftAmount = new BigDecimal((context.giftAmount).add(amount));

[MSG]Semicolons as line endings can be removed safely

UnnecessaryGString370

[SRC]else if ("CREDIT_CARD".equals(paymentInfo.paymentMethodTypeId)) {

[MSG]The String 'CREDIT_CARD' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon371

[SRC]context.creditAmount = new BigDecimal((context.creditAmo..dd(amount));

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon373

[SRC]context.totalPay = new BigDecimal((context.totalPay).add(amount));

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon377

[SRC]context.shoppingCart = shoppingCart;

[MSG]Semicolons as line endings can be removed safely

UnnecessarySemicolon379

[SRC]context.shoppingCartSize = 0;

[MSG]Semicolons as line endings can be removed safely

SpaceAroundMapEntryColon382

[SRC]context.paymentCash = from("PaymentMethodType").where(...queryOne();

[MSG]The colon for the literal Map entry for key [paymentMethodTypeId] within class org.apache.ofbiz.webpos.cart.None is not preceded by a match for regular expression [\S]

UnnecessaryGString382

[SRC]context.paymentCash = from("PaymentMethodType").where(...queryOne();

[MSG]The String 'PaymentMethodType' can be wrapped in single quotes instead of double quotes

UnnecessaryGString382

[SRC]context.paymentCash = from("PaymentMethodType").where(...queryOne();

[MSG]The String 'paymentMethodTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString382

[SRC]context.paymentCash = from("PaymentMethodType").where(...queryOne();

[MSG]The String 'CASH' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon382

[SRC]context.paymentCash = from("PaymentMethodType").where(...queryOne();

[MSG]Semicolons as line endings can be removed safely

SpaceAroundMapEntryColon383

[SRC]context.paymentCheck = from("PaymentMethodType").where(...queryOne();

[MSG]The colon for the literal Map entry for key [paymentMethodTypeId] within class org.apache.ofbiz.webpos.cart.None is not preceded by a match for regular expression [\S]

UnnecessaryGString383

[SRC]context.paymentCheck = from("PaymentMethodType").where(...queryOne();

[MSG]The String 'PaymentMethodType' can be wrapped in single quotes instead of double quotes

UnnecessaryGString383

[SRC]context.paymentCheck = from("PaymentMethodType").where(...queryOne();

[MSG]The String 'paymentMethodTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString383

[SRC]context.paymentCheck = from("PaymentMethodType").where(...queryOne();

[MSG]The String 'PERSONAL_CHECK' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon383

[SRC]context.paymentCheck = from("PaymentMethodType").where(...queryOne();

[MSG]Semicolons as line endings can be removed safely

SpaceAroundMapEntryColon384

[SRC]context.paymentGift = from("PaymentMethodType").where(...queryOne();

[MSG]The colon for the literal Map entry for key [paymentMethodTypeId] within class org.apache.ofbiz.webpos.cart.None is not preceded by a match for regular expression [\S]

UnnecessaryGString384

[SRC]context.paymentGift = from("PaymentMethodType").where(...queryOne();

[MSG]The String 'PaymentMethodType' can be wrapped in single quotes instead of double quotes

UnnecessaryGString384

[SRC]context.paymentGift = from("PaymentMethodType").where(...queryOne();

[MSG]The String 'paymentMethodTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString384

[SRC]context.paymentGift = from("PaymentMethodType").where(...queryOne();

[MSG]The String 'GIFT_CARD' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon384

[SRC]context.paymentGift = from("PaymentMethodType").where(...queryOne();

[MSG]Semicolons as line endings can be removed safely

SpaceAroundMapEntryColon385

[SRC]context.paymentCredit = from("PaymentMethodType").where(...queryOne();

[MSG]The colon for the literal Map entry for key [paymentMethodTypeId] within class org.apache.ofbiz.webpos.cart.None is not preceded by a match for regular expression [\S]

UnnecessaryGString385

[SRC]context.paymentCredit = from("PaymentMethodType").where(...queryOne();

[MSG]The String 'PaymentMethodType' can be wrapped in single quotes instead of double quotes

UnnecessaryGString385

[SRC]context.paymentCredit = from("PaymentMethodType").where(...queryOne();

[MSG]The String 'paymentMethodTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString385

[SRC]context.paymentCredit = from("PaymentMethodType").where(...queryOne();

[MSG]The String 'CREDIT_CARD' can be wrapped in single quotes instead of double quotes

UnnecessarySemicolon385

[SRC]context.paymentCredit = from("PaymentMethodType").where(...queryOne();

[MSG]Semicolons as line endings can be removed safely

Package: org.apache.ofbiz.webpos.catalog

➥ Category.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGString329

[SRC]detailScreen = "categorydetail"

[MSG]The String 'categorydetail' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]if (!(productCategoryId) && request.getAttribute("topCategoryId")) {

[MSG]The String 'topCategoryId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]productCategoryId = request.getAttribute("topCategoryId")

[MSG]The String 'topCategoryId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]category = from("ProductCategory").where("productCategor..).queryOne()

[MSG]The String 'ProductCategory' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]category = from("ProductCategory").where("productCategor..).queryOne()

[MSG]The String 'productCategoryId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]context.title = categoryContentWrapper.get("CATEGORY_NAME", "html")

[MSG]The String 'CATEGORY_NAME' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]context.title = categoryContentWrapper.get("CATEGORY_NAME", "html")

[MSG]The String 'html' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]categoryDescription = categoryContentWrapper.get("DESCRI..ON", "html")

[MSG]The String 'DESCRIPTION' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]categoryDescription = categoryContentWrapper.get("DESCRI..ON", "html")

[MSG]The String 'html' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]context.metaKeywords = categoryDescription + ", " + catalogName

[MSG]The String ', ' can be wrapped in single quotes instead of double quotes

UnnecessaryGString361

[SRC]request.setAttribute("productCategoryId", productCategoryId)

[MSG]The String 'productCategoryId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString362

[SRC]request.setAttribute("defaultViewSize", 10)

[MSG]The String 'defaultViewSize' can be wrapped in single quotes instead of double quotes

UnnecessaryGString363

[SRC]request.setAttribute("limitView", true)

[MSG]The String 'limitView' can be wrapped in single quotes instead of double quotes

➥ SideDeepCategory.groovy

Rule NamePriorityLine #Source Line / Message
LineLength224

[SRC]CategoryWorker.getRelatedCategories(request, "topLevelLi..est)), true)

[MSG]The line exceeds 150 characters. The line is 158 characters.

UnnecessaryGString324

[SRC]CategoryWorker.getRelatedCategories(request, "topLevelLi..est)), true)

[MSG]The String 'topLevelList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString325

[SRC]curCategoryId = parameters.category_id ?: parameters.CATEGORY_ID ?: ""

[MSG]The String '' can be wrapped in single quotes instead of double quotes

UnnecessaryGString326

[SRC]request.setAttribute("curCategoryId", curCategoryId)

[MSG]The String 'curCategoryId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]categoryList = request.getAttribute("topLevelList")

[MSG]The String 'topLevelList' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]request.setAttribute("topCategoryId", curCategoryId)

[MSG]The String 'topCategoryId' can be wrapped in single quotes instead of double quotes

Package: org.apache.ofbiz.webpos.customer

➥ EditAddress.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGString321

[SRC]person = from("Person").where("partyId", parameters.part..).queryOne()

[MSG]The String 'Person' can be wrapped in single quotes instead of double quotes

UnnecessaryGString321

[SRC]person = from("Person").where("partyId", parameters.part..).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString323

[SRC]request.setAttribute("lastName", person.lastName)

[MSG]The String 'lastName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString324

[SRC]request.setAttribute("firstName", person.firstName)

[MSG]The String 'firstName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString325

[SRC]request.setAttribute("partyId", parameters.partyId)

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]contactMech = from("ContactMech").where("contactMechId",..).queryOne()

[MSG]The String 'ContactMech' can be wrapped in single quotes instead of double quotes

UnnecessaryGString328

[SRC]contactMech = from("ContactMech").where("contactMechId",..).queryOne()

[MSG]The String 'contactMechId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString330

[SRC]postalAddress = contactMech.getRelatedOne("PostalAddress", false)

[MSG]The String 'PostalAddress' can be wrapped in single quotes instead of double quotes

UnnecessaryGString332

[SRC]request.setAttribute("contactMechId", postalAddress.contactMechId)

[MSG]The String 'contactMechId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]request.setAttribute("toName", postalAddress.toName)

[MSG]The String 'toName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]request.setAttribute("attnName", postalAddress.attnName)

[MSG]The String 'attnName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]request.setAttribute("address1", postalAddress.address1)

[MSG]The String 'address1' can be wrapped in single quotes instead of double quotes

UnnecessaryGString336

[SRC]request.setAttribute("address2", postalAddress.address2)

[MSG]The String 'address2' can be wrapped in single quotes instead of double quotes

UnnecessaryGString337

[SRC]request.setAttribute("city", postalAddress.city)

[MSG]The String 'city' can be wrapped in single quotes instead of double quotes

UnnecessaryGString338

[SRC]request.setAttribute("postalCode", postalAddress.postalCode)

[MSG]The String 'postalCode' can be wrapped in single quotes instead of double quotes

UnnecessaryGString339

[SRC]request.setAttribute("stateProvinceGeoId", postalAddress..ovinceGeoId)

[MSG]The String 'stateProvinceGeoId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]request.setAttribute("countryGeoId", postalAddress.countryGeoId)

[MSG]The String 'countryGeoId' can be wrapped in single quotes instead of double quotes

UnnecessaryObjectReferences340

[SRC]request.setAttribute("countryGeoId", postalAddress.countryGeoId)

[MSG]The code could be more concise by using a with() or identity() block

UnnecessaryGString341

[SRC]stateProvinceGeo = from("Geo").where("geoId", postalAddr..).queryOne()

[MSG]The String 'Geo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString341

[SRC]stateProvinceGeo = from("Geo").where("geoId", postalAddr..).queryOne()

[MSG]The String 'geoId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]request.setAttribute("stateProvinceGeo", stateProvinceGe..e", locale))

[MSG]The String 'stateProvinceGeo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString343

[SRC]request.setAttribute("stateProvinceGeo", stateProvinceGe..e", locale))

[MSG]The String 'geoName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString345

[SRC]countryProvinceGeo = from("Geo").where("geoId", postalAd..).queryOne()

[MSG]The String 'Geo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString345

[SRC]countryProvinceGeo = from("Geo").where("geoId", postalAd..).queryOne()

[MSG]The String 'geoId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]request.setAttribute("countryProvinceGeo", countryProvin..e", locale))

[MSG]The String 'countryProvinceGeo' can be wrapped in single quotes instead of double quotes

UnnecessaryGString347

[SRC]request.setAttribute("countryProvinceGeo", countryProvin..e", locale))

[MSG]The String 'geoName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString351

[SRC]request.setAttribute("contactMechPurposeTypeId", paramet..rposeTypeId)

[MSG]The String 'contactMechPurposeTypeId' can be wrapped in single quotes instead of double quotes

Package: org.apache.ofbiz.webpos.manager

➥ PaidOutAndIn.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGString321

[SRC]context.paidReasonIn = from("Enumeration").where("enumT...queryList()

[MSG]The String 'Enumeration' can be wrapped in single quotes instead of double quotes

UnnecessaryGString321

[SRC]context.paidReasonIn = from("Enumeration").where("enumT...queryList()

[MSG]The String 'enumTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString321

[SRC]context.paidReasonIn = from("Enumeration").where("enumT...queryList()

[MSG]The String 'POS_PAID_REASON_IN' can be wrapped in single quotes instead of double quotes

UnnecessaryGString321

[SRC]context.paidReasonIn = from("Enumeration").where("enumT...queryList()

[MSG]The String 'sequenceId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString322

[SRC]context.paidReasonOut = from("Enumeration").where("enumT...queryList()

[MSG]The String 'Enumeration' can be wrapped in single quotes instead of double quotes

UnnecessaryGString322

[SRC]context.paidReasonOut = from("Enumeration").where("enumT...queryList()

[MSG]The String 'enumTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString322

[SRC]context.paidReasonOut = from("Enumeration").where("enumT...queryList()

[MSG]The String 'POS_PAID_REASON_OUT' can be wrapped in single quotes instead of double quotes

UnnecessaryGString322

[SRC]context.paidReasonOut = from("Enumeration").where("enumT...queryList()

[MSG]The String 'sequenceId' can be wrapped in single quotes instead of double quotes

Package: org.apache.ofbiz.webpos.search

➥ CustomerAddress.groovy

Rule NamePriorityLine #Source Line / Message
ExplicitCallToEqualsMethod234

[SRC]if (contactMech && "POSTAL_ADDRESS".equals(contactMech.c..chTypeId)) {

[MSG]Violation in class org.apache.ofbiz.webpos.search.None. Explicit call to POSTAL_ADDRESS.equals(contactMech.contactMechTypeId) method can be rewritten as (POSTAL_ADDRESS == (contactMech.contactMechTypeId))

ExplicitCallToEqualsMethod245

[SRC]if (contactMech && "POSTAL_ADDRESS".equals(contactMech.c..chTypeId)) {

[MSG]Violation in class org.apache.ofbiz.webpos.search.None. Explicit call to POSTAL_ADDRESS.equals(contactMech.contactMechTypeId) method can be rewritten as (POSTAL_ADDRESS == (contactMech.contactMechTypeId))

UnusedImport321

[SRC]import org.apache.ofbiz.base.util.UtilValidate

[MSG]The [org.apache.ofbiz.base.util.UtilValidate] import is never referenced

UnnecessaryGString329

[SRC]context.personShipTo = from("Person").where("partyId", s..).queryOne()

[MSG]The String 'Person' can be wrapped in single quotes instead of double quotes

UnnecessaryGString329

[SRC]context.personShipTo = from("Person").where("partyId", s..).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString331

[SRC]shippingContactMechId = shoppingCart.getContactMech("SHI..G_LOCATION")

[MSG]The String 'SHIPPING_LOCATION' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]contactMech = from("ContactMech").where("contactMechId",..).queryOne()

[MSG]The String 'ContactMech' can be wrapped in single quotes instead of double quotes

UnnecessaryGString333

[SRC]contactMech = from("ContactMech").where("contactMechId",..).queryOne()

[MSG]The String 'contactMechId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString334

[SRC]if (contactMech && "POSTAL_ADDRESS".equals(contactMech.c..chTypeId)) {

[MSG]The String 'POSTAL_ADDRESS' can be wrapped in single quotes instead of double quotes

UnnecessaryGString335

[SRC]context.shippingPostalAddress = contactMech.getRelatedOn..ess", false)

[MSG]The String 'PostalAddress' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]context.personBillTo = from("Person").where("partyId", b..).queryOne()

[MSG]The String 'Person' can be wrapped in single quotes instead of double quotes

UnnecessaryGString340

[SRC]context.personBillTo = from("Person").where("partyId", b..).queryOne()

[MSG]The String 'partyId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString342

[SRC]billingContactMechId = shoppingCart.getContactMech("BILLING_LOCATION")

[MSG]The String 'BILLING_LOCATION' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]contactMech = from("ContactMech").where("contactMechId",..).queryOne()

[MSG]The String 'ContactMech' can be wrapped in single quotes instead of double quotes

UnnecessaryGString344

[SRC]contactMech = from("ContactMech").where("contactMechId",..).queryOne()

[MSG]The String 'contactMechId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString345

[SRC]if (contactMech && "POSTAL_ADDRESS".equals(contactMech.c..chTypeId)) {

[MSG]The String 'POSTAL_ADDRESS' can be wrapped in single quotes instead of double quotes

UnnecessaryGString346

[SRC]context.billingPostalAddress = contactMech.getRelatedOne..ess", false)

[MSG]The String 'PostalAddress' can be wrapped in single quotes instead of double quotes

➥ SearchSalesReps.groovy

Rule NamePriorityLine #Source Line / Message
UnnecessaryGString321

[SRC]context.salesReps = from("PartyRoleNameDetail").where("r...queryList()

[MSG]The String 'PartyRoleNameDetail' can be wrapped in single quotes instead of double quotes

UnnecessaryGString321

[SRC]context.salesReps = from("PartyRoleNameDetail").where("r...queryList()

[MSG]The String 'roleTypeId' can be wrapped in single quotes instead of double quotes

UnnecessaryGString321

[SRC]context.salesReps = from("PartyRoleNameDetail").where("r...queryList()

[MSG]The String 'SALES_REP' can be wrapped in single quotes instead of double quotes

UnnecessaryGString321

[SRC]context.salesReps = from("PartyRoleNameDetail").where("r...queryList()

[MSG]The String 'lastName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString321

[SRC]context.salesReps = from("PartyRoleNameDetail").where("r...queryList()

[MSG]The String 'firstName' can be wrapped in single quotes instead of double quotes

UnnecessaryGString323

[SRC]shoppingCart = session.getAttribute("shoppingCart")

[MSG]The String 'shoppingCart' can be wrapped in single quotes instead of double quotes

Package: org.apache.ofbiz.webtools.labelmanager

➥ LabelManager.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.webtools.labelmanager.LabelManagerFactory

ImportFromSamePackage322

[SRC]import org.apache.ofbiz.webtools.labelmanager.LabelReferences

➥ UpdateManager.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.webtools.labelmanager.LabelManagerFactory

➥ ViewReferences.groovy

Rule NamePriorityLine #Source Line / Message
ImportFromSamePackage321

[SRC]import org.apache.ofbiz.webtools.labelmanager.LabelManagerFactory

ImportFromSamePackage322

[SRC]import org.apache.ofbiz.webtools.labelmanager.LabelReferences

Package: org.apache.ofbiz.webtools.service

➥ SetServiceParameters.groovy

Rule NamePriorityLine #Source Line / Message
ConsecutiveBlankLines399

[MSG]File SetServiceParameters.groovy has consecutive blank lines

Rule Descriptions

#Rule NameDescription
1AbstractClassNameVerifies that the name of an abstract class matches a regular expression specified in the regex property. If that property is null or empty, then this rule is not applied (i.e., it does nothing). It defaults to null, so this rule must be explicitly configured to be active. This rule ignores interfaces.
2AbstractClassWithPublicConstructorChecks for abstract classes that define a public constructor, which is useless and confusing.
3AbstractClassWithoutAbstractMethodThe abstract class does not contain any abstract methods. An abstract class suggests an incomplete implementation, which is to be completed by subclasses implementing the abstract methods. If the class is intended to be used as a base class only (not to be instantiated direcly) a protected constructor can be provided prevent direct instantiation.
4AddEmptyStringFinds empty string literals which are being added. This is an inefficient way to convert any type to a String.
5AssertWithinFinallyBlockChecks for assert statements within a finally block. An assert can throw an exception, hiding the original exception, if there is one.
6AssignCollectionSortThe Collections.sort() method mutates the list and returns the list as a value. If you are assigning the result of sort() to a variable, then you probably don't realize that you're also modifying the original list as well. This is frequently the cause of subtle bugs.
7AssignCollectionUniqueThe Collections.unique() method mutates the list and returns the list as a value. If you are assigning the result of unique() to a variable, then you probably don't realize that you're also modifying the original list as well. This is frequently the cause of subtle bugs.
8AssignmentInConditionalAn assignment operator (=) was used in a conditional test. This is usually a typo, and the comparison operator (==) was intended.
9AssignmentToStaticFieldFromInstanceMethodChecks for assignment to a static field from an instance method.
10BigDecimalInstantiationChecks for calls to the BigDecimal constructors that take a double parameter, which may result in an unexpected BigDecimal value.
11BitwiseOperatorInConditionalChecks for bitwise operations in conditionals, if you need to do a bitwise operation then it is best practice to extract a temp variable.
12BlankLineBeforePackageMakes sure there are no blank lines before the package declaration of a source code file.
13BlockEndsWithBlankLineChecks that code blocks such as method bodies, closures and control structure bodies do not end with an empty line.
14BlockStartsWithBlankLineChecks that code blocks such as method bodies, closures and control structure bodies do not start with an empty line.
15BooleanGetBooleanThis rule catches usages of java.lang.Boolean.getBoolean(String) which reads a boolean from the System properties. It is often mistakenly used to attempt to read user input or parse a String into a boolean. It is a poor piece of API to use; replace it with System.properties['prop'].
16BooleanMethodReturnsNullMethod with Boolean return type returns explicit null. A method that returns either Boolean.TRUE, Boolean.FALSE or null is an accident waiting to happen. This method can be invoked as though it returned a value of type boolean, and the compiler will insert automatic unboxing of the Boolean value. If a null value is returned, this will result in a NullPointerException.
17BracesForClassChecks the location of the opening brace ({) for classes. By default, requires them on the same line, but the sameLine property can be set to false to override this.
18BracesForForLoopChecks the location of the opening brace ({) for for loops. By default, requires them on the same line, but the sameLine property can be set to false to override this.
19BracesForIfElseChecks the location of the opening brace ({) for if statements. By default, requires them on the same line, but the sameLine property can be set to false to override this.
20BracesForMethodChecks the location of the opening brace ({) for constructors and methods. By default, requires them on the same line, but the sameLine property can be set to false to override this.
21BracesForTryCatchFinallyChecks the location of the opening brace ({) for try statements. By default, requires them on the line, but the sameLine property can be set to false to override this.
22BrokenNullCheckLooks for faulty checks for null that can cause a NullPointerException.
23BrokenOddnessCheckThe code uses x % 2 == 1 to check to see if a value is odd, but this won't work for negative numbers (e.g., (-5) % 2 == -1). If this code is intending to check for oddness, consider using x & 1 == 1, or x % 2 != 0.
24BuilderMethodWithSideEffectsA builder method is defined as one that creates objects. As such, they should never be of void return type. If a method is named build, create, or make, then it should always return a value.
25BusyWaitBusy waiting (forcing a Thread.sleep() while waiting on a condition) should be avoided. Prefer using the gate and barrier objects in the java.util.concurrent package.
26CatchArrayIndexOutOfBoundsExceptionCheck the size of the array before accessing an array element rather than catching ArrayIndexOutOfBoundsException.
27CatchErrorCatching Error is dangerous; it can catch exceptions such as ThreadDeath and OutOfMemoryError.
28CatchIllegalMonitorStateExceptionDubious catching of IllegalMonitorStateException. IllegalMonitorStateException is generally only thrown in case of a design flaw in your code (calling wait or notify on an object you do not hold a lock on).
29CatchIndexOutOfBoundsExceptionCheck that an index is valid before accessing an indexed element rather than catching IndexOutOfBoundsException.
30CatchNullPointerExceptionCatching NullPointerException is never appropriate. It should be avoided in the first place with proper null checking, and it can mask underlying errors.
31CatchRuntimeExceptionCatching RuntimeException is often too broad or general. It should usually be restricted to framework or infrastructure code, rather than application code.
32CatchThrowableCatching Throwable is dangerous; it can catch exceptions such as ThreadDeath and OutOfMemoryError.
33ChainedTestA test method that invokes another test method is a chained test; the methods are dependent on one another. Tests should be isolated, and not be dependent on one another.
34ClassEndsWithBlankLineCheck whether the class ends with a blank line.By default, it enforces that there must be a blank line before the closing class brace, except if the class is empty and is written in a single line. A blank line is defined as any line that does not contain any visible characters.
35ClassForNameUsing Class.forName(...) is a common way to add dynamic behavior to a system. However, using this method can cause resource leaks because the classes can be pinned in memory for long periods of time.
36ClassNameVerifies that the name of a class matches a regular expression. By default it checks that the class name starts with an uppercase letter and is followed by zero or more word characters (letters, numbers or underscores). The regex property specifies the regular expression used to validate the class name.
37ClassNameSameAsFilenameReports files containing only one top level class / enum / interface which is named differently than the file.
38ClassNameSameAsSuperclassChecks for any class that has an identical name to its superclass, other than the package. This can be very confusing.
39ClassSizeChecks if the size of a class exceeds the number of lines specified by the maxLines property (1000).
40ClassStartsWithBlankLineCheck whether the class starts with a blank line By default, it enforces that there must be a blank line after the opening class brace, except if the class is empty and is written in a single line. A blank line is defined as any line that does not contain any visible characters.
41CloneableWithoutCloneA class that implements java.lang.Cloneable should define a clone() method.
42CloseWithoutCloseableIf a class defines a "void close()" then that class should implement java.io.Closeable or java.lang.AutoCloseable.
43ClosureAsLastMethodParameterIf a method is called and the last parameter is an inline closure then it can be declared outside of the method call brackets.
44ClosureStatementOnOpeningLineOfMultipleLineClosureChecks for closure logic on first line (after ->) for a multi-line closure.
45CollectAllIsDeprecatedcollectAll{} is deprecated since Groovy 1.8.1. Use collectNested instead{}.
46CompareToWithoutComparableIf you implement a compareTo method then you should also implement the Comparable interface.
47ComparisonOfTwoConstantsChecks for expressions where a comparison operator or equals() or compareTo() is used to compare two constants to each other or two literals that contain only constant values., e.g.: 23 == 67, Boolean.FALSE != false, 0.17 <= 0.99, "abc" > "ddd", [a:1] <=> [a:2], [1,2].equals([3,4]) or [a:false, b:true].compareTo(['a':34.5, b:Boolean.TRUE].
48ComparisonWithSelfChecks for expressions where a comparison operator or equals() or compareTo() is used to compare a variable to itself, e.g.: x == x, x != x, x <=> x, x < x, x =>= x, x.equals(x) or x.compareTo(x), where x is a variable.
49ConfusingClassNamedExceptionThis class is not derived from another exception, but ends with 'Exception'. This will be confusing to users of this class.
50ConfusingMethodNameChecks for confusing method names. The referenced methods have names that differ only by capitalization. This is very confusing because if the capitalization were identical then one of the methods would override the other.
51ConfusingMultipleReturnsMultiple return values can be used to set several variables at once. To use multiple return values, the left hand side of the assignment must be enclosed in parenthesis. If not, then you are not using multiple return values, you're only assigning the last element.
52ConfusingTernaryIn a ternary expression avoid negation in the test. For example, rephrase: "(x != y) ? diff : same" as: "(x == y) ? same : diff". Consistent use of this rule makes the code easier to read. Also, this resolves trivial ordering problems, such as "does the error case go first?" or "does the common case go first?".
53ConsecutiveBlankLinesMakes sure there are no consecutive lines that are either blank or whitespace only.
54ConsecutiveLiteralAppendsViolations occur when method calls to append(Object) are chained together with literals as parameters. The chained calls can be joined into one invocation.
55ConsecutiveStringConcatenationCatches concatenation of two string literals on the same line. These can safely by joined.
56ConstantAssertExpressionChecks for assert statements where the assert boolean condition expression is a constant or literal value.
57ConstantIfExpressionChecks for if statements with a constant value for the if expression, such as true, false, null, or a literal constant value.
58ConstantTernaryExpressionChecks for ternary expressions with a constant value for the boolean expression, such as true, false, null, or a literal constant value.
59ConstantsOnlyInterfaceAn interface should be used only to model a behaviour of a class: using an interface as a container of constants is a poor usage pattern.
60CouldBeElvisCatch an if block that could be written as an elvis expression.
61CouldBeSwitchStatementChecks for multiple if statements that could be converted to a switch
62CoupledTestCaseThis rule finds test cases that are coupled to other test cases, either by invoking static methods on another test case or by creating instances of another test case. If you require shared logic in test cases then extract that logic to a new class where it can properly be reused.
63CrapMetricChecks the CRAP (Change Risk Anti-Patterns) score for methods/classes. The CRAP metric score is based on the cyclomatic complexity and test coverage for individual methods. A method with a CRAP value greater than the maxMethodCrapScore property (30) causes a violation. Likewise, a class that has an (average method) CRAP value greater than the maxClassAverageMethodCrapScore property (30) causes a violation.
64DeadCodeDead code appears after a return statement or an exception is thrown. If code appears after one of these statements then it will never be executed and can be safely deleted.
65DirectConnectionManagementThe J2EE standard requires that applications use the container's resource management facilities to obtain connections to resources. Every major web application container provides pooled database connection management as part of its resource management framework. Duplicating this functionality in an application is difficult and error prone, which is part of the reason it is forbidden under the J2EE standard.
66DoubleCheckedLockingThis rule detects double checked locking, where a 'lock hint' is tested for null before initializing an object within a synchronized block. Double checked locking does not guarantee correctness and is an anti-pattern.
67DoubleNegativeThere is no point in using a double negative, it is always positive. For instance !!x can always be simplified to x. And !(!x) can as well.
68DuplicateCaseStatementCheck for duplicate case statements in a switch block, such as two equal integers or strings.
69DuplicateImportDuplicate import statements are unnecessary.
70DuplicateMapKeyA map literal is created with duplicated key. The map entry will be overwritten.
71DuplicateSetValueA Set literal is created with duplicate constant value. A set cannot contain two elements with the same value.
72ElseBlockBracesUse braces for else blocks, even for a single statement. By default, braces are not required for an else if it is followed immediately by an if. Set the bracesRequiredForElseIf property to true to require braces is that situation as well.
73EmptyCatchBlockIn most cases, exceptions should not be caught and ignored (swallowed).
74EmptyClassReports classes without methods, fields or properties. Why would you need a class like this?
75EmptyElseBlockEmpty else blocks are confusing and serve no purpose.
76EmptyFinallyBlockEmpty finally blocks are confusing and serve no purpose.
77EmptyForStatementEmpty for statements are confusing and serve no purpose.
78EmptyIfStatementEmpty if statements are confusing and serve no purpose.
79EmptyInstanceInitializerAn empty class instance initializer was found. It is safe to remove it.
80EmptyMethodA method was found without an implementation. If the method is overriding or implementing a parent method, then mark it with the @Override annotation.
81EmptyMethodInAbstractClassAn empty method in an abstract class should be abstract instead, as developer may rely on this empty implementation rather than code the appropriate one.
82EmptyStaticInitializerAn empty static initializer was found. It is safe to remove it.
83EmptySwitchStatementEmpty switch statements are confusing and serve no purpose.
84EmptySynchronizedStatementEmpty synchronized statements are confusing and serve no purpose.
85EmptyTryBlockEmpty try blocks are confusing and serve no purpose.
86EmptyWhileStatementEmpty while statements are confusing and serve no purpose.
87EnumCustomSerializationIgnoredChecks for enums that define writeObject() or writeReplace() methods, or declare serialPersistentFields or serialVersionUID fields, all of which are ignored for enums.
88EqualsAndHashCodeIf either the boolean equals(Object) or the int hashCode() methods are overridden within a class, then both must be overridden.
89EqualsOverloadedThe class has an equals method, but the parameter of the method is not of type Object. It is not overriding equals but instead overloading it.
90ExceptionExtendsErrorErrors are system exceptions. Do not extend them.
91ExceptionExtendsThrowableChecks for classes that extend java.lang.Throwable. Custom exception classes should subclass java.lang.Exception or one of its descendants.
92ExceptionNotThrownChecks for an exception constructor call without a throw as the last statement within a catch block.
93ExplicitArrayListInstantiationThis rule checks for the explicit instantiation of an ArrayList using the no-arg constructor. In Groovy, it is best to write new ArrayList() as [], which creates the same object.
94ExplicitCallToAndMethodThis rule detects when the and(Object) method is called directly in code instead of using the & operator. A groovier way to express this: a.and(b) is this: a & b
95ExplicitCallToCompareToMethodThis rule detects when the compareTo(Object) method is called directly in code instead of using the <=>, >, >=, <, and <= operators. A groovier way to express this: a.compareTo(b) is this: a <=> b, or using the other operators.
96ExplicitCallToDivMethodThis rule detects when the div(Object) method is called directly in code instead of using the / operator. A groovier way to express this: a.div(b) is this: a / b
97ExplicitCallToEqualsMethodThis rule detects when the equals(Object) method is called directly in code instead of using the == or != operator. A groovier way to express this: a.equals(b) is this: a == b and a groovier way to express : !a.equals(b) is : a != b
98ExplicitCallToGetAtMethodThis rule detects when the getAt(Object) method is called directly in code instead of using the [] index operator. A groovier way to express this: a.getAt(b) is this: a[b]
99ExplicitCallToLeftShiftMethodThis rule detects when the leftShift(Object) method is called directly in code instead of using the << operator. A groovier way to express this: a.leftShift(b) is this: a << b
100ExplicitCallToMinusMethodThis rule detects when the minus(Object) method is called directly in code instead of using the - operator. A groovier way to express this: a.minus(b) is this: a - b
101ExplicitCallToModMethodThis rule detects when the mod(Object) method is called directly in code instead of using the % operator. A groovier way to express this: a.mod(b) is this: a % b
102ExplicitCallToMultiplyMethodThis rule detects when the minus(Object) method is called directly in code instead of using the * operator. A groovier way to express this: a.multiply(b) is this: a * b
103ExplicitCallToOrMethodThis rule detects when the or(Object) method is called directly in code instead of using the | operator. A groovier way to express this: a.or(b) is this: a | b
104ExplicitCallToPlusMethodThis rule detects when the plus(Object) method is called directly in code instead of using the + operator. A groovier way to express this: a.plus(b) is this: a + b
105ExplicitCallToPowerMethodThis rule detects when the power(Object) method is called directly in code instead of using the ** operator. A groovier way to express this: a.power(b) is this: a ** b
106ExplicitCallToPutAtMethodDetects when the putAt(Object, Object) method is called directly in code instead of using the [] index operator. A groovier way to express this: map.putAt(k, v) is this: map[k] = v.
107ExplicitCallToRightShiftMethodThis rule detects when the rightShift(Object) method is called directly in code instead of using the >> operator. A groovier way to express this: a.rightShift(b) is this: a >> b
108ExplicitCallToXorMethodThis rule detects when the xor(Object) method is called directly in code instead of using the ^ operator. A groovier way to express this: a.xor(b) is this: a ^ b
109ExplicitGarbageCollectionCalls to System.gc(), Runtime.getRuntime().gc(), and System.runFinalization() are not advised. Code should have the same behavior whether the garbage collection is disabled using the option -Xdisableexplicitgc or not. Moreover, "modern" jvms do a very good job handling garbage collections. If memory usage issues unrelated to memory leaks develop within an application, it should be dealt with JVM options rather than within the code itself.
110ExplicitHashMapInstantiationThis rule checks for the explicit instantiation of a HashMap using the no-arg constructor. In Groovy, it is best to write new HashMap() as [:], which creates the same object.
111ExplicitHashSetInstantiationThis rule checks for the explicit instantiation of a HashSet using the no-arg constructor. In Groovy, it is best to write new HashSet() as [] as Set, which creates the same object.
112ExplicitLinkedHashMapInstantiationThis rule checks for the explicit instantiation of a LinkedHashMap using the no-arg constructor. In Groovy, it is best to write new LinkedHashMap() as [:], which creates the same object.
113ExplicitLinkedListInstantiationThis rule checks for the explicit instantiation of a LinkedList using the no-arg constructor. In Groovy, it is best to write new LinkedList() as [] as Queue, which creates the same object.
114ExplicitStackInstantiationThis rule checks for the explicit instantiation of a Stack using the no-arg constructor. In Groovy, it is best to write new Stack() as [] as Stack, which creates the same object.
115ExplicitTreeSetInstantiationThis rule checks for the explicit instantiation of a TreeSet using the no-arg constructor. In Groovy, it is best to write new TreeSet() as [] as SortedSet, which creates the same object.
116FieldNameVerifies that the name of each field matches a regular expression. By default it checks that non-'final' field names start with a lowercase letter and contains only letters or numbers, and 'final' field names start with an uppercase letter and contain only uppercase letters, numbers and underscores. The regex property specifies the default regular expression used to validate field names. The finalRegex property specifies the regular expression to validate 'final' field names. The staticRegex property specifies the regular expression to validate 'static' field names. The staticFinalRegex property specifies the regular expression to validate 'static final' field names. The ignoreFieldNames property (serialVersionUID)can specify field names that should be ignored, optionally containing wildcard characters ('*' or '?').
117FieldTypeRequiredChecks that field types are explicitly specified (and not using def).
118FileCreateTempFileThe File.createTempFile() method is insecure, and has been deprecated by the ESAPI secure coding library. It has been replaced by the ESAPI Randomizer.getRandomFilename(String) method.
119FileEndsWithoutNewlineMakes sure the source code file ends with a newline character.
120FinalClassWithProtectedMemberThis rule finds classes marked final that contain protected methods. If a class is final then it may not be subclassed, and there is therefore no point in having a method with protected visibility. Either the class should not be final or the method should be private or protected.
121ForLoopShouldBeWhileLoopA for loop without an init and update statement can be simplified to a while loop.
122ForStatementBracesUse braces for for statements, even for a single statement.
123GStringAsMapKeyA GString should not be used as a map key since its hashcode is not guaranteed to be stable. Consider calling key.toString().
124GStringExpressionWithinStringCheck for regular (single quote) strings containing a GString-type expression (${...}).
125GetterMethodCouldBePropertyIf a class defines a public method that follows the Java getter notation, and returns a constant, then it is cleaner to provide a Groovy property for the value rather than a Groovy method.
126GrailsDomainHasEqualsChecks that Grails domain classes redefine equals().
127GrailsDomainHasToStringChecks that Grails domain classes redefine toString()
128GrailsDomainReservedSqlKeywordNameForbids usage of SQL reserved keywords as class or field names in Grails domain classes. Naming a domain class (or its field) with such a keyword causes SQL schema creation errors and/or redundant table/column name mappings.
129GrailsDomainStringPropertyMaxSizeString properties in Grails domain classes have to define maximum size otherwise the property is mapped to VARCHAR(255) causing runtime exceptions to occur
130GrailsDomainWithServiceReferenceChecks that Grails domain classes do not have service classes injected.
131GrailsDuplicateConstraintCheck for duplicate entry in domain class constraints
132GrailsDuplicateMappingCheck for duplicate name in a domain class mapping
133GrailsMassAssignmentUntrusted input should not be allowed to set arbitrary object fields without restriction.
134GrailsServletContextReferenceChecks for references to the servletContext object from within Grails controller and taglib classes.
135GrailsStatelessServiceChecks for fields on Grails service classes. Grails service classes are singletons, by default, and so they should be reentrant and typically stateless. The ignoreFieldNames property (dataSource,scope,sessionFactory,transactional,*Service,grailsApplication) specifies one or more field names that should be ignored. The ignoreFieldTypes property (null) specifies one or more field type names that should be ignored. Both can optionally contain wildcard characters ('*' or '?').
136GroovyLangImmutableThe groovy.lang.Immutable annotation has been deprecated and replaced by groovy.transform.Immutable. Do not use the Immutable in groovy.lang.
137HardCodedWindowsFileSeparatorThis rule finds usages of a Windows file separator within the constructor call of a File object. It is better to use the Unix file separator or use the File.separator constant.
138HardCodedWindowsRootDirectoryThis rule find cases where a File object is constructed with a windows-based path. This is not portable, and using the File.listRoots() method is a better alternative.
139HashtableIsObsoleteThe java.util.Hashtable class is effectively obsolete. Use the Java Collections Framework classes instead, including HashMap or ConcurrentHashMap. See the JDK javadoc.
140IfStatementBracesUse braces for if statements, even for a single statement.
141IfStatementCouldBeTernaryChecks for if statements where both the if and else blocks contain only a single return statement with a constant or literal value
142IllegalClassMemberChecks for classes containing fields/properties/methods matching configured illegal member modifiers or not matching any of the configured allowed member modifiers.
143IllegalClassReferenceChecks for reference to any of the classes configured in classNames.
144IllegalPackageReferenceChecks for reference to any of the packages configured in packageNames.
145IllegalRegexChecks for a specified illegal regular expression within the source code. The regex property specifies the regular expression to check for. It is required and cannot be null or empty.
146IllegalStringChecks for a specified illegal string within the source code.
147IllegalSubclassChecks for classes that extend one of the specified set of illegal superclasses configured in superclassNames.
148ImplementationAsTypeChecks for use of a predefined set of concrete classes (e.g. ArrayList, Hashtable, ConcurrentHashMap) when specifying the type of a method parameter, closure parameter, constructor parameter, method return type or field type. The associated interfaces should be used to specify the type instead.
149ImportFromSamePackageAn import of a class that is within the same package is unnecessary.
150ImportFromSunPackagesAvoid importing anything from the 'sun.*' packages. These packages are not portable and are likely to change.
151InconsistentPropertyLockingClass contains similarly-named get and set methods where one method of the pair is marked either @WithReadLock or @WithWriteLock and the other is not locked at all.
152InconsistentPropertySynchronizationClass contains similarly-named get and set methods where the set method is synchronized and the get method is not, or the get method is synchronized and the set method is not.
153IndentationCheck indentation for class and method declarations, and initial statements.
154InsecureRandomReports usages of java.util.Random, which can produce very predictable results. If two instances of Random are created with the same seed and sequence of method calls, they will generate the exact same results. Use java.security.SecureRandom instead, which provides a cryptographically strong random number generator. SecureRandom uses PRNG, which means they are using a deterministic algorithm to produce a pseudo-random number from a true random seed. SecureRandom produces non-deterministic output.
155IntegerGetIntegerThis rule catches usages of java.lang.Integer.getInteger(String, ...) which reads an Integer from the System properties. It is often mistakenly used to attempt to read user input or parse a String into an Integer. It is a poor piece of API to use; replace it with System.properties['prop'].
156InterfaceNameVerifies that the name of an interface matches a regular expression specified in the regex property. If that property is null or empty, then this rule is not applied (i.e., it does nothing). It defaults to null, so this rule must be explicitly configured to be active.
157InterfaceNameSameAsSuperInterfaceChecks for any interface that has an identical name to its super-interface, other than the package. This can be very confusing.
158InvertedConditionAn inverted condition is one where a constant expression is used on the left hand side of the equals comparision. Such conditions can be confusing especially when used in assertions where the expected value is by convention placed on the right hand side of the comparision.
159InvertedIfElseAn inverted if-else statement is one in which there is a single if statement with a single else branch and the boolean test of the if is negated. For instance if (!x) false else true. It is usually clearer to write this as if (x) true else false.
160JUnitAssertAlwaysFailsChecks for JUnit assert() method calls with constant arguments such that the assertion always fails. This includes: assertTrue(false), assertFalse(true) and assertNull(CONSTANT).
161JUnitAssertAlwaysSucceedsChecks for JUnit assert() method calls with constant arguments such that the assertion always succeeds. This includes: assertTrue(true), assertFalse(false) and assertNull(null).
162JUnitFailWithoutMessageThis rule detects JUnit calling the fail() method without an argument. For better error reporting you should always provide a message.
163JUnitLostTestChecks for classes that import JUnit 4 classes and contain a public, instance, void, no-arg method named test* that is not annotated with @Test.
164JUnitPublicFieldChecks for public field on a JUnit test class
165JUnitPublicNonTestMethodChecks if a JUnit test class contains public methods other than standard test methods, JUnit framework methods or methods with JUnit annotations.
166JUnitPublicPropertyChecks for public properties defined on JUnit test classes. There should be no need to expose a public property on a test class.
167JUnitSetUpCallsSuperChecks that if the JUnit setUp() method is defined, that it includes a call to super.setUp().
168JUnitStyleAssertionsThis rule detects calling JUnit style assertions like assertEquals, assertTrue, assertFalse, assertNull, assertNotNull. Groovy ships with a feature called the "power assert", which is an assert statement with better error reporting. This is preferable to the JUnit assertions.
169JUnitTearDownCallsSuperChecks that if the JUnit tearDown() method is defined, that it includes a call to super.tearDown().
170JUnitTestMethodWithoutAssertThis rule searches for test methods that do not contain assert statements. Either the test method is missing assert statements, which is an error, or the test method contains custom assert statements that do not follow a proper assert naming convention. Test methods are defined as public void methods that begin with the work test or have a @Test annotation. By default this rule applies to the default test class names, but this can be changed using the rule's applyToClassNames property.
171JUnitUnnecessarySetUpChecks for JUnit setUp() methods that contain only a call to super.setUp().
172JUnitUnnecessaryTearDownChecks for JUnit tearDown() methods that contain only a call to super.tearDown().
173JUnitUnnecessaryThrowsExceptionCheck for throws clauses on JUnit test methods. That is not necessary in Groovy.
174JavadocConsecutiveEmptyLinesChecks for javadoc comments with more than one consecutive empty line.
175JavadocEmptyAuthorTagChecks for empty @author tags within javadoc.
176JavadocEmptyExceptionTagChecks for empty @exception tag within javadoc.
177JavadocEmptyFirstLineCheck for javadoc comments with an empty top line.
178JavadocEmptyLastLineCheck for javadoc comments with an empty line at the bottom.
179JavadocEmptyParamTagChecks for empty @param tags within javadoc.
180JavadocEmptyReturnTagChecks for empty @return tags within javadoc.
181JavadocEmptySeeTagChecks for empty @see tags within javadoc.
182JavadocEmptySinceTagChecks for empty @since tags within javadoc.
183JavadocEmptyThrowsTagChecks for empty @throws tag within javadoc
184JavadocEmptyVersionTagChecks for empty @version tags within javadoc.
185JavadocMissingExceptionDescriptionChecks for missing description within @exception javadoc tags.
186JavadocMissingParamDescriptionChecks for missing description within @param javadoc tags.
187JavadocMissingThrowsDescriptionChecks for missing description within @throws javadoc tags.
188JdbcConnectionReferenceCheck for direct use of java.sql.Connection, which is discouraged and almost never necessary in application code.
189JdbcStatementReferenceCheck for direct use of java.sql.Statement, java.sql.PreparedStatement, or java.sql.CallableStatement, which is not necessary if using the Groovy Sql facility or an ORM framework such as Hibernate.
190LineLengthChecks the maximum length for each line of source code. It checks for number of characters, so lines that include tabs may appear longer than the allowed number when viewing the file. The maximum line length can be configured by setting the length property, which defaults to 120.
191LocaleSetDefaultChecks for calls to Locale.setDefault(), which sets the Locale across the entire JVM.
192LoggerForDifferentClassChecks for instantiating a logger (Log4J, SLF4J, Logback, Apache Commons Logging or Java Util Logging) for a class other than the current class.
193LoggerWithWrongModifiersLogger objects should be declared private, static and final. If subclasses should have access to a Logger in a parent class then the Logger should be declared protected, non-static and final. This rule find loggers that are not declared with these modifiers.
194LoggingSwallowsStacktraceIf you are logging an exception then the proper API is to call error(Object, Throwable), which will log the message and the exception stack trace. If you call error(Object) then the stacktrace may not be logged.
195LongLiteralWithLowerCaseLIn Java and Groovy, you can specify long literals with the L or l character, for instance 55L or 24l. It is best practice to always use an uppercase L and never a lowercase l. This is because 11l rendered in some fonts may look like 111 instead of 11L.
196MethodCountA class with too many methods is probably a good suspect for refactoring, in order to reduce its complexity and find a way to have more fine grained objects.The maxMethods property (30) specifies the threshold.
197MethodNameVerifies that the name of each method matches a regular expression. By default it checks that the method name starts with a lowercase letter. The regex property specifies the regular expression to check the method name against. The ignoreMethodNames property (null) can specify method names that should be ignored, optionally containing wildcard characters ('*' or '?').
198MethodParameterTypeRequiredChecks that method parameters are not dynamically typed, that is they are explicitly stated and different than def.
199MethodReturnTypeRequiredChecks that method return types are not dynamic, that is they are explicitly stated and different than def.
200MisorderedStaticImportsStatic imports should never be declared after nonstatic imports.
201MissingBlankLineAfterImportsMakes sure there is a blank line after the imports of a source code file.
202MissingBlankLineAfterPackageMakes sure there is a blank line after the package statement of a source code file.
203MissingNewInThrowStatementA common Groovy mistake when throwing exceptions is to forget the new keyword. For instance, "throw RuntimeException()" instead of "throw new RuntimeException()". If the error path is not unit tested then the production system will throw a Method Missing exception and hide the root cause. This rule finds constructs like "throw RuntimeException()" that look like a new keyword was meant to be used but forgotten.
204MultipleLoggersThis rule catches classes that have more than one logger object defined. Typically, a class has zero or one logger objects.
205MultipleUnaryOperatorsChecks for multiple consecutive unary operators. These are confusing, and are likely typos and bugs.
206NestedForLoopReports classes with nested for loops.
207NestedSynchronizationNested synchronized statements should be avoided. Nested synchronized statements are either useless (if the lock objects are identical) or prone to deadlock.
208NoDefdef should not be used. You should replace it with concrete type.
209NoDoubleChecks for use of the double or Double types, in fields, variables, method parameters and method return types.
210NoFloatChecks for use of the float or Float types, in fields, variables, method parameters and method return types.
211NoJavaUtilDateDo not use java.util.Date. Prefer the classes in the java.time.* packages.
212NoTabCharacterChecks that all source files do not contain the tab character
213NoWildcardImportsWildcard imports, static or otherwise, should not be used.
214NonFinalPublicFieldFinds code that violates secure coding principles for mobile code by declaring a member variable public but not final.
215NonFinalSubclassOfSensitiveInterfaceThe permissions classes such as java.security.Permission and java.security.BasicPermission are designed to be extended. Classes that derive from these permissions classes, however, must prohibit extension. This prohibition ensures that malicious subclasses cannot change the properties of the derived class. Classes that implement sensitive interfaces such as java.security.PrivilegedAction and java.security.PrivilegedActionException must also be declared final for analogous reasons.
216ObjectFinalizeThe finalize() method should only be called by the JVM after the object has been garbage collected.
217ObjectOverrideMisspelledMethodNameVerifies that the names of the most commonly overridden methods of Object: equals, hashCode and toString, are correct.
218PackageNameVerifies that the package name for a class matches a regular expression. By default it checks that the package name consists of only lowercase letters, separated by periods. The regex property specifies the regular expression used to validate the package name. The packageNameRequired property indicates whether a package name declaration is required for all classes.
219PackageNameMatchesFilePathA package source file's path should match the package itself. To find the package-relevant subpath in the file path the groupId needs to be configured. It is expected in every package declaration.
220ParameterNameVerifies that the name of each parameter matches a regular expression. This rule applies to method parameters, constructor parameters and closure parameters. By default it checks that parameter names start with a lowercase letter and contains only letters or numbers. The regex property specifies the default regular expression used to validate the parameter name. The ignoreParameterNames property (null) can specify parameter names that should be ignored, optionally containing wildcard characters ('*' or '?').
221PrintStackTraceChecks for calls to printStackTrace().
222PrintlnChecks for calls to this.print(), this.println() or this.printf().
223PrivateFieldCouldBeFinalChecks for private fields that are only set within a constructor or field initializer. Such fields can safely be made final.
224PropertyNameVerifies that the name of each property matches a regular expression. By default it checks that property names other than 'static final' start with a lowercase letter and contains only letters or numbers, and 'static final' property names start with an uppercase letter and contain only uppercase letters, numbers and underscores. The regex property specifies the default regular expression used to validate property names. The finalRegex property specifies the regular expression to validate 'final' property names. The staticRegex property specifies the regular expression to validate 'static' property names. The staticFinalRegex property specifies the regular expression to validate 'static final' property names. The ignorePropertyNames property (null) can specify property names that should be ignored, optionally containing wildcard characters ('*' or '?').
225PublicFinalizeMethodCreates a violation when the program violates secure coding principles by declaring a finalize() method public.
226PublicInstanceFieldUsing public fields is considered to be a bad design. Use properties instead.
227PublicMethodsBeforeNonPublicMethodsEnforce that all public methods are above protected and private methods.
228RandomDoubleCoercedToZeroThe Math.random() method returns a double result greater than or equal to 0.0 and less than 1.0. If you coerce this result into an Integer or int, then it is coerced to zero. Casting the result to int, or assigning it to an int field is probably a bug.
229RemoveAllOnSelfDon't use removeAll to clear a collection. If you want to remove all elements from a collection c, use c.clear, not c.removeAll(c). Calling c.removeAll(c) to clear a collection is less clear, susceptible to errors from typos, less efficient and for some collections, might throw a ConcurrentModificationException.
230RequiredRegexChecks for a specified regular expression that must exist within the source code. The regex property specifies the regular expression to check for. It is required and cannot be null or empty.
231RequiredStringChecks for a specified text string that must exist within the source code. The string property specifies the String to check for. It is required and cannot be null or empty.
232ReturnFromFinallyBlockReturning from a finally block is confusing and can hide the original exception.
233ReturnNullFromCatchBlockReturning null from a catch block often masks errors and requires the client to handle error codes. In some coding styles this is discouraged.
234ReturnsNullInsteadOfEmptyArrayConsider returning a zero length array rather than null. It is often a better design to return a length zero array rather than a null reference to indicate that there are no results (i.e., an empty list of results). This way, no explicit check for null is needed by clients of the method.
235ReturnsNullInsteadOfEmptyCollectionConsider returning a zero length collection rather than null. It is often a better design to return a length zero collection rather than a null reference to indicate that there are no results (i.e., an empty list of results). This way, no explicit check for null is needed by clients of the method.
236SerialPersistentFieldsTo use a Serializable object's serialPersistentFields correctly, it must be declared private, static, and final.
237SerialVersionUIDA serialVersionUID is normally intended to be used with Serialization. It needs to be of type long, static, and final. Also, it should have a visibility modifier such as public or private. Providing no modifier creates a Property and Groovy generates a getter, which is probably not intended.
238SerializableClassMustDefineSerialVersionUIDClasses that implement Serializable should define a serialVersionUID. If you don't define serialVersionUID, the system will make one by hashing most of your class's features. Then if you change anything, the UID will change and Java won't let you reload old data.
239SimpleDateFormatMissingLocaleBe sure to specify a Locale when creating a new instance of SimpleDateFormat; the class is locale-sensitive. If you instantiate SimpleDateFormat without a Locale parameter, it will format the date and time according to the default Locale. Both the pattern and the Locale determine the format. For the same pattern, SimpleDateFormat may format a date and time differently if the Locale varies.
240SpaceAfterCatchCheck that there is exactly one space (blank) after the catch keyword and before the opening parenthesis.
241SpaceAfterClosingBraceCheck that there is at least one space (blank) or whitespace after each closing brace ("}") for method/class/interface declarations, closure expressions and block statements.
242SpaceAfterCommaChecks that there is at least one space or whitespace following each comma. That includes checks for method and closure declaration parameter lists, method call parameter lists, Map literals and List literals.
243SpaceAfterForCheck that there is exactly one space (blank) after the for keyword and before the opening parenthesis.
244SpaceAfterIfCheck that there is exactly one space (blank) after the if keyword and before the opening parenthesis.
245SpaceAfterOpeningBraceCheck that there is at least one space (blank) or whitespace after each opening brace ("{") for method/class/interface declarations, closure expressions and block statements.
246SpaceAfterSemicolonChecks that there is at least one space or whitespace following each semicolon separating multiple statements on a single line or the clauses within a classic for loop.
247SpaceAfterSwitchCheck that there is exactly one space (blank) after the switch keyword and before the opening parenthesis.
248SpaceAfterWhileCheck that there is exactly one space (blank) after the while keyword and before the opening parenthesis.
249SpaceAroundClosureArrowChecks that there is whitespace around the closure arrow (->) symbol
250SpaceAroundMapEntryColonCheck for configured formatting of whitespace around colons for literal Map entries. The characterBeforeColonRegex and characterAfterColonRegex properties specify a regular expression that must match the character before/after the colon.
251SpaceAroundOperatorCheck that there is at least one space (blank) or whitespace around each binary operator.
252SpaceBeforeClosingBraceCheck that there is at least one space (blank) or whitespace before each closing brace ("}") for method/class/interface declarations, closure expressions and block statements.
253SpaceBeforeOpeningBraceCheck that there is at least one space (blank) or whitespace before each opening brace ("{") for method/class/interface declarations, closure expressions and block statements.
254SpockIgnoreRestUsedIf Spock's @IgnoreRest appears on any method, all non-annotated test methods are not executed. This behaviour is almost always unintended. It's fine to use @IgnoreRest locally during development, but when committing code, it should be removed.
255StatelessClassChecks for fields on classes that should remain "stateless" and reentrant. The ignoreFieldNames property (null) specifies one or more field names that should be ignored. The ignoreFieldTypes property specifies one or more field type names that should be ignored. Both can optionally contain wildcard characters ('*' or '?').
256StatelessSingletonThere is no point in creating a stateless Singleton because there is nothing within the class that needs guarding and no side effects to calling the constructor. Just create new instances of the object or write a Utility class with static methods.
257StaticCalendarFieldCalendar objects should not be used as static fields. Calendars are inherently unsafe for multihtreaded use. Sharing a single instance across thread boundaries without proper synchronization will result in erratic behavior of the application.
258StaticConnectionCreates violations when a java.sql.Connection object is used as a static field. Database connections stored in static fields will be shared between threads, which is unsafe and can lead to race conditions.
259StaticDateFormatFieldDateFormat objects should not be used as static fields. DateFormat are inherently unsafe for multithreaded use. Sharing a single instance across thread boundaries without proper synchronization will result in erratic behavior of the application.
260StaticFieldsBeforeInstanceFieldsEnforce that all static fields are above all instance fields within a class
261StaticMatcherFieldMatcher objects should not be used as static fields. Matcher instances are inherently unsafe for multithreaded use. Sharing a single instance across thread boundaries without proper synchronization will result in erratic behavior of the application.
262StaticMethodsBeforeInstanceMethodsEnforce that all static methods are above all instance methods within a class
263StaticSimpleDateFormatFieldSimpleDateFormat objects should not be used as static fields. SimpleDateFormat are inherently unsafe for multi-threaded use. Sharing a single instance across thread boundaries without proper synchronization will result in erratic behavior of the application.
264SwallowThreadDeathChecks for code that catches ThreadDeath without re-throwing it.
265SynchronizedMethodThis rule reports uses of the synchronized keyword on methods. Synchronized methods are the same as synchronizing on 'this', which effectively make your synchronization policy public and modifiable by other objects. To avoid possibilities of deadlock, it is better to synchronize on internal objects.
266SynchronizedOnBoxedPrimitiveThe code synchronizes on a boxed primitive constant, such as an Integer. Since Integer objects can be cached and shared, this code could be synchronizing on the same object as other, unrelated code, leading to unresponsiveness and possible deadlock
267SynchronizedOnGetClassSynchronization on getClass rather than class literal. This instance method synchronizes on this.getClass(). If this class is subclassed, subclasses will synchronize on the class object for the subclass, which isn't likely what was intended.
268SynchronizedOnReentrantLockSynchronizing on a ReentrantLock field is almost never the intended usage. A ReentrantLock should be obtained using the lock() method and released in a finally block using the unlock() method.
269SynchronizedOnStringSynchronization on a String field can lead to deadlock because Strings are interned by the JVM and can be shared.
270SynchronizedOnThisThis rule reports uses of the synchronized blocks where the synchronization reference is 'this'. Doing this effectively makes your synchronization policy public and modifiable by other objects. To avoid possibilities of deadlock, it is better to synchronize on internal objects.
271SynchronizedReadObjectMethodCatches Serializable classes that define a synchronized readObject method. By definition, an object created by deserialization is only reachable by one thread, and thus there is no need for readObject() to be synchronized. If the readObject() method itself is causing the object to become visible to another thread, that is an example of very dubious coding style.
272SystemErrPrintChecks for calls to System.err.print(), System.err.println() or System.err.printf().
273SystemExitWeb applications should never call System.exit(). A call to System.exit() is probably part of leftover debug code or code imported from a non-J2EE application.
274SystemOutPrintChecks for calls to System.out.print(), System.out.println() or System.out.printf().
275SystemRunFinalizersOnExitMethod calls to System.runFinalizersOnExit() should not be allowed. This method is inherently non-thread-safe, may result in data corruption, deadlock, and may effect parts of the program far removed from it's call point. It is deprecated, and it's use strongly discouraged.
276TernaryCouldBeElvisChecks for ternary expressions where the boolean and true expressions are the same. These can be simplified to an Elvis expression.
277ThisReferenceEscapesConstructorReports constructors passing the 'this' reference to other methods. This equals exposing a half-baked objects and can lead to race conditions during initialization. For reference, see Java Concurrency Gotchas by Alex Miller and Java theory and practice: Safe construction techniques by Brian Goetz.
278ThreadLocalNotStaticFinalThreadLocal fields should be static and final. In the most common case a java.lang.ThreadLocal instance associates state with a thread. A non-static non-final java.lang.ThreadLocal field associates state with an instance-thread combination. This is seldom necessary and often a bug which can cause memory leaks and possibly incorrect behavior.
279ThreadYieldMethod calls to Thread.yield() should not be allowed. This method has no useful guaranteed semantics, and is often used by inexperienced programmers to mask race conditions.
280ThrowErrorChecks for throwing an instance of java.lang.Error.
281ThrowExceptionChecks for throwing an instance of java.lang.Exception.
282ThrowExceptionFromFinallyBlockThrowing an exception from a finally block is confusing and can hide the original exception.
283ThrowNullPointerExceptionChecks for throwing an instance of java.lang.NullPointerException.
284ThrowRuntimeExceptionChecks for throwing an instance of java.lang.RuntimeException.
285ThrowThrowableChecks for throwing an instance of java.lang.Throwable.
286ToStringReturnsNullChecks for toString() methods that return null.
287TrailingWhitespaceChecks that no lines of source code end with whitespace characters.
288UnnecessaryBigDecimalInstantiationIt is unnecessary to instantiate BigDecimal objects. Instead just use the decimal literal or the 'G' identifier to force the type, such as 123.45 or 123.45G.
289UnnecessaryBigIntegerInstantiationIt is unnecessary to instantiate BigInteger objects. Instead just use the literal with the 'G' identifier to force the type, such as 8G or 42G.
290UnnecessaryBooleanExpressionChecks for unnecessary boolean expressions, including ANDing (&&) or ORing (||) with true, false, null, or a Map/List/String/Number literal. Also checks for negation (!) of true, false, null, or a Map/List/String/Number literal.
291UnnecessaryBooleanInstantiationUse Boolean.valueOf() for variable values or Boolean.TRUE and Boolean.FALSE for constant values instead of calling the Boolean() constructor directly or calling Boolean.valueOf(true) or Boolean.valueOf(false).
292UnnecessaryCallForLastElementThis rule checks for excessively verbose methods of accessing the last element of an array or list. For instance, it is possible to access the last element of an array by performing array[array.length - 1], in Groovy it is simpler to either call array.last() or array[-1]. The same is true for lists. This violation is triggered whenever a get, getAt, or array-style access is used with an object size check.
293UnnecessaryCallToSubstringCalling String.substring(0) always returns the original string. This code is meaningless.
294UnnecessaryCastChecks for unnecessary cast operations
295UnnecessaryCatchBlockViolations are triggered when a catch block does nothing but throw the original exception. In this scenario there is usually no need for a catch block, just let the exception be thrown from the original code. This condition frequently occurs when catching an exception for debugging purposes but then forgetting to take the catch statement out.
296UnnecessaryCollectCallSome method calls to Object.collect(Closure) can be replaced with the spread operator. For instance, list.collect { it.multiply(2) } can be replaced by list*.multiply(2). Warning: if a collection is null, collect will return an empty list, while *. will return null.
297UnnecessaryCollectionCallUseless call to collections. This call doesn't make sense. For any collection c, calling c.containsAll(c) should always be true, and c.retainAll(c) should have no effect.
298UnnecessaryConstructorThis rule detects when a constructor is not necessary; i.e., when there's only one constructor, it's public, has an empty body, and takes no arguments.
299UnnecessaryDefInFieldDeclarationIf a field has a visibility modifier or a type declaration, then the def keyword is unneeded. For instance, 'static def constraints = {}' is redundant and can be simplified to 'static constraints = {}.
300UnnecessaryDefInMethodDeclarationIf a method has a visibility modifier or a type declaration, then the def keyword is unneeded. For instance 'def private method() {}' is redundant and can be simplified to 'private method() {}'.
301UnnecessaryDefInVariableDeclarationIf a variable has a visibility modifier or a type declaration, then the def keyword is unneeded. For instance 'def private n = 2' is redundant and can be simplified to 'private n = 2'.
302UnnecessaryDotClassTo make a reference to a class, it is unnecessary to specify the '.class' identifier. For instance String.class can be shortened to String.
303UnnecessaryDoubleInstantiationIt is unnecessary to instantiate Double objects. Instead just use the double literal or the 'D' identifier to force the type, such as 123.45d or 0.42d.
304UnnecessaryElseStatementWhen an if statement block ends with a return statement the else is unnecessary. The logic in the else branch can be run without being in a new scope.
305UnnecessaryFailIn a unit test, catching an exception and immediately calling Assert.fail() is pointless and hides the stack trace. It is better to rethrow the exception or not catch the exception at all.
306UnnecessaryFinalOnPrivateMethodA private method is marked final. Private methods cannot be overridden, so marking it final is unnecessary.
307UnnecessaryFloatInstantiationIt is unnecessary to instantiate Float objects. Instead just use the float literal with the 'F' identifier to force the type, such as 123.45F or 0.42f.
308UnnecessaryGStringString objects should be created with single quotes, and GString objects created with double quotes. Creating normal String objects with double quotes is confusing to readers.
309UnnecessaryGroovyImportA Groovy file does not need to include an import for classes from java.lang, java.util, java.io, java.net, groovy.lang and groovy.util, as well as the classes java.math.BigDecimal and java.math.BigInteger.
310UnnecessaryIfStatementChecks for if statements where the if and else blocks (or subsequent fall-through to a return) are merely returning true and false constants. These cases can be replaced by a simple return statement.
311UnnecessaryInstanceOfCheckThis rule finds instanceof checks that cannot possibly evaluate to true. For instance, checking that (!variable instanceof String) will never be true because the result of a not expression is always a boolean.
312UnnecessaryInstantiationToGetClassAvoid instantiating an object just to call getClass() on it; use the .class public member instead.
313UnnecessaryIntegerInstantiationIt is unnecessary to instantiate Integer objects. Instead just use the literal with the 'I' identifier to force the type, such as 8I or 42i.
314UnnecessaryLongInstantiationIt is unnecessary to instantiate Long objects. Instead just use the literal with the 'L' identifier to force the type, such as 8L or 42L.
315UnnecessaryModOneAny expression mod 1 (exp % 1) is guaranteed to always return zero. This code is probably an error, and should be either (exp & 1) or (exp % 2).
316UnnecessaryNullCheckGroovy contains the safe dereference operator, which can be used in boolean conditional statements to safely replace explicit "x == null" tests.
317UnnecessaryNullCheckBeforeInstanceOfThere is no need to check for null before an instanceof; the instanceof keyword returns false when given a null argument.
318UnnecessaryObjectReferencesViolations are triggered when an excessive set of consecutive statements all reference the same variable. This can be made more readable by using a with or identity block.
319UnnecessaryOverridingMethodThe overriding method merely calls the same method defined in a superclass
320UnnecessaryPackageReferenceChecks for explicit package reference for classes that Groovy imports by default, such as java.lang.String, java.util.Map and groovy.lang.Closure.
321UnnecessaryParenthesesForMethodCallWithClosureIf a method is called and the only parameter to that method is an inline closure then the parentheses of the method call can be omitted.
322UnnecessaryPublicModifierThe 'public' modifier is not required on methods or classes.
323UnnecessarySafeNavigationOperatorCheck for the safe navigation operator (?.) applied to constants and literals, which can never be null.
324UnnecessarySelfAssignmentMethod contains a pointless self-assignment to a variable or property.
325UnnecessarySemicolonSemicolons as line terminators are not required in Groovy: remove them. Do not use a semicolon as a replacement for empty braces on for and while loops; this is a confusing practice.
326UnnecessaryStringInstantiationUse a String literal (e.g., "...") instead of calling the corresponding String constructor (new String("..")) directly.
327UnnecessaryTernaryExpressionChecks for ternary expressions where the conditional expression always evaluates to a boolean and the true and false expressions are merely returning true and false constants. Also checks for ternary expressions where both expressions are the same constant or variable.
328UnnecessaryToStringChecks for unnecessary calls to toString().
329UnnecessaryTransientModifierThe field is marked as transient, but the class isn't Serializable, so marking it as transient has no effect.
330UnsafeArrayDeclarationTriggers a violation when an array is declared public, final, and static. Secure coding principles state that, in most cases, an array declared public, final and static is a bug because arrays are mutable objects.
331UnusedArrayChecks for array allocations that are not assigned or used, unless it is the last statement within a block.
332UnusedImportImports for a class that is never referenced within the source file is unnecessary.
333UnusedMethodParameterThis rule finds instances of method parameters not being used. It does not analyze private methods (that is done by the UnusedPrivateMethodParameter rule) or methods marked @Override.
334UnusedObjectChecks for object allocations that are not assigned or used, unless it is the last statement within a block
335UnusedPrivateFieldChecks for private fields that are not referenced within the same class.
336UnusedPrivateMethodChecks for private methods that are not referenced within the same class.
337UnusedPrivateMethodParameterChecks for parameters to private methods that are not referenced within the method body.
338UnusedVariableChecks for variables that are never referenced. The ignoreVariableNames property (null) specifies one or more variable names that should be ignored, optionally containing wildcard characters ('*' or '?').
339UseAssertEqualsInsteadOfAssertTrueThis rule detects JUnit assertions in object equality. These assertions should be made by more specific methods, like assertEquals.
340UseAssertFalseInsteadOfNegationIn unit tests, if a condition is expected to be false then there is no sense using assertTrue with the negation operator. For instance, assertTrue(!condition) can always be simplified to assertFalse(condition)
341UseAssertNullInsteadOfAssertEqualsThis rule detects JUnit calling assertEquals where the first or second parameter is null. These assertion should be made against the assertNull method instead.
342UseAssertSameInsteadOfAssertTrueThis rule detects JUnit calling assertTrue where the first or second parameter is an Object#is() call testing for reference equality. These assertion should be made against the assertSame method instead.
343UseAssertTrueInsteadOfAssertEqualsThis rule detects JUnit calling assertEquals where the first parameter is a boolean. These assertions should be made by more specific methods, like assertTrue or assertFalse.
344UseAssertTrueInsteadOfNegationIn unit tests, if a condition is expected to be true then there is no sense using assertFalse with the negation operator. For instance, assertFalse(!condition) can always be simplified to assertTrue(condition)
345UseCollectManyIn many case collectMany() yields the same result as collect{}.flatten(). It is easier to understand and more clearly conveys the intent.
346UseCollectNestedInstead of nested collect{}-calls use collectNested{}
347UseOfNotifyMethodThis code calls notify() rather than notifyAll(). Java monitors are often used for multiple conditions. Calling notify() only wakes up one thread, meaning that the thread woken up might not be the one waiting for the condition that the caller just satisfied.
348VariableNameVerifies that the name of each method matches a regular expression. By default it checks that non-'final' variable names start with a lowercase letter and contains only letters or numbers, and 'final' variable names start with an uppercase letter and contain only uppercase letters, numbers and underscores. The regex property specifies the default regular expression used to validate a non-'final' variable name. The finalRegex property specifies the regular expression used to validate 'final' variable names. The ignoreVariableNames property (null) can specify variable names that should be ignored, optionally containing wildcard characters ('*' or '?').
349VariableTypeRequiredChecks that variable types are explicitly specified in declarations (and not using def)
350VectorIsObsoleteThe java.util.Vector class is effectively obsolete. Use the Java Collections Framework classes instead, including ArrayList or Collections.synchronizedList(). See the JDK javadoc.
351VolatileArrayFieldVolatile array fields are unsafe because the contents of the array are not treated as volatile. Changing the entire array reference is visible to other threads, but changing an array element is not.
352VolatileLongOrDoubleFieldLong or double fields should not be declared as volatile. Java specifies that reads and writes from such fields are atomic, but many JVM's have violated this specification. Unless you are certain of your JVM, it is better to synchronize access to such fields rather than declare them volatile. This rule flags fields marked volatile when their type is double or long or the name of their type is "Double" or "Long".
353WaitOutsideOfWhileLoopCalls to Object.wait() must be within a while loop. Consider using the Java concurrency utilities instead of wait() and notify().
354WhileStatementBracesUse braces for while statements, even for a single statement.