Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0036437Openbravo ERPA. Platformpublic2017-07-06 13:442017-07-07 10:24
shuehner 
shuehner 
normalminorhave not tried
closedfixed 
5
 
3.0PR17Q4 
alostale
Core
No
0036437: Avoid using Vector<Object> when only single type of data is used in the list (platform part)
Vector<Object> or any other of Object only make sense when planning to save several types of data inside the list.

When only stores i.e. Strings or objects of some other single class it does not make sense to use Vector<Object>:
- as no benefit
- harder to read + debug
- need extra casts when retrieving data

So this issue is about fixing simple cases which break this.

Note: Cases are selected as:
a.) simply fixable
b.) causing issues in latest release of some external code-checking tool (checkerframework)
-
No tags attached.
related to defect 0036436 closed Triage Omni OMS Avoid using Vector<Object> when only single type of data is used in the list (functional part) 
diff vector-object-platform.diff (16,098) 2017-07-06 13:44
https://issues.openbravo.com/file_download.php?file_id=10897&type=bug
Issue History
2017-07-06 13:44shuehnerNew Issue
2017-07-06 13:44shuehnerAssigned To => platform
2017-07-06 13:44shuehnerModules => Core
2017-07-06 13:44shuehnerTriggers an Emergency Pack => No
2017-07-06 13:44shuehnerRelationship addedrelated to 0036436
2017-07-06 13:44shuehnerFile Added: vector-object-platform.diff
2017-07-06 13:45shuehnerNote Added: 0097911
2017-07-07 10:16alostaleAssigned Toplatform => shuehner
2017-07-07 10:16alostaleReview Assigned To => alostale
2017-07-07 10:22hgbotCheckin
2017-07-07 10:22hgbotNote Added: 0097933
2017-07-07 10:22hgbotStatusnew => resolved
2017-07-07 10:22hgbotResolutionopen => fixed
2017-07-07 10:22hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/08518044d2b0f5f7d237f3fe54e4c78b3e4cb41a [^]
2017-07-07 10:24alostaleNote Added: 0097935
2017-07-07 10:24alostaleStatusresolved => closed
2017-07-07 10:24alostaleFixed in Version => 3.0PR17Q4

Notes
(0097911)
shuehner   
2017-07-06 13:45   
Patch is compiled tested only. While mechanical simple changes only please check careful.
Note: Patch changes SqlC code-generator but for this change no need to update + re-commit all buildvalidations+modulescripts
(0097933)
hgbot   
2017-07-07 10:22   
Repository: erp/devel/pi
Changeset: 08518044d2b0f5f7d237f3fe54e4c78b3e4cb41a
Author: Stefan Hühner <stefan.huehner <at> openbravo.com>
Date: Fri Jul 07 10:16:07 2017 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/08518044d2b0f5f7d237f3fe54e4c78b3e4cb41a [^]

fixed 36437: Avoid using Vector<Object> when only single type of data is used

  In the cases when a single type of data is used, define Vector with the more
  specific type.

---
M src-core/src/org/openbravo/data/Sqlc.java
M src/org/openbravo/erpCommon/ad_actionButton/ActionButtonUtility.java
M src/org/openbravo/erpCommon/ad_forms/SQLExecutor_Query.java
M src/org/openbravo/erpCommon/ad_forms/ShowSessionVariables.java
M src/org/openbravo/erpCommon/ad_process/AlertProcess.java
M src/org/openbravo/erpCommon/businessUtility/Buscador.java
M src/org/openbravo/erpCommon/businessUtility/TabFilter.java
---
(0097935)
alostale   
2017-07-07 10:24   
reviewed