IDEMPIERE-455 Discover and fix FindBugs problems / Pattern GC_UNRELATED_TYPES (Thanks to Richard Morales)
This commit is contained in:
parent
0ae714b5ca
commit
3f02050b41
|
@ -97,7 +97,7 @@ public class GridTable extends AbstractTableModel
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
private static final long serialVersionUID = 2328810326636468776L;
|
private static final long serialVersionUID = -3181940154166340664L;
|
||||||
|
|
||||||
public static final String DATA_REFRESH_MESSAGE = "Refreshed";
|
public static final String DATA_REFRESH_MESSAGE = "Refreshed";
|
||||||
|
|
||||||
|
@ -109,7 +109,7 @@ public class GridTable extends AbstractTableModel
|
||||||
* @param TableName table name
|
* @param TableName table name
|
||||||
* @param WindowNo window no
|
* @param WindowNo window no
|
||||||
* @param TabNo tab no
|
* @param TabNo tab no
|
||||||
* @param withAccessControl if true adds AD_Client/Org restrictuins
|
* @param withAccessControl if true adds AD_Client/Org restrictions
|
||||||
*/
|
*/
|
||||||
public GridTable(Properties ctx, int AD_Table_ID, String TableName, int WindowNo, int TabNo,
|
public GridTable(Properties ctx, int AD_Table_ID, String TableName, int WindowNo, int TabNo,
|
||||||
boolean withAccessControl)
|
boolean withAccessControl)
|
||||||
|
@ -878,7 +878,6 @@ public class GridTable extends AbstractTableModel
|
||||||
* @param col col
|
* @param col col
|
||||||
* @param ascending ascending
|
* @param ascending ascending
|
||||||
*/
|
*/
|
||||||
@SuppressWarnings("unchecked")
|
|
||||||
public void sort (int col, boolean ascending)
|
public void sort (int col, boolean ascending)
|
||||||
{
|
{
|
||||||
log.info("#" + col + " " + ascending);
|
log.info("#" + col + " " + ascending);
|
||||||
|
@ -1144,7 +1143,7 @@ public class GridTable extends AbstractTableModel
|
||||||
Collections.reverse(toremove);
|
Collections.reverse(toremove);
|
||||||
for(Integer row : toremove)
|
for(Integer row : toremove)
|
||||||
{
|
{
|
||||||
m_sort.remove(row);
|
m_sort.remove(row.intValue());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -117,7 +117,7 @@ public class MClientShare extends X_AD_ClientShare
|
||||||
s_shares.put("0_0", Boolean.TRUE);
|
s_shares.put("0_0", Boolean.TRUE);
|
||||||
} // load
|
} // load
|
||||||
StringBuilder key = new StringBuilder().append(AD_Client_ID).append("_").append(AD_Table_ID);
|
StringBuilder key = new StringBuilder().append(AD_Client_ID).append("_").append(AD_Table_ID);
|
||||||
return s_shares.get(key);
|
return s_shares.get(key.toString());
|
||||||
} // load
|
} // load
|
||||||
|
|
||||||
/** Shared Info */
|
/** Shared Info */
|
||||||
|
|
|
@ -363,7 +363,7 @@ public class MLookupFactory
|
||||||
{
|
{
|
||||||
// Try cache - assume no language change
|
// Try cache - assume no language change
|
||||||
StringBuilder key = new StringBuilder().append(Env.getAD_Client_ID(ctx)).append("|").append(String.valueOf(AD_Reference_Value_ID));
|
StringBuilder key = new StringBuilder().append(Env.getAD_Client_ID(ctx)).append("|").append(String.valueOf(AD_Reference_Value_ID));
|
||||||
MLookupInfo retValue = (MLookupInfo)s_cacheRefTable.get(key);
|
MLookupInfo retValue = (MLookupInfo)s_cacheRefTable.get(key.toString());
|
||||||
if (retValue != null)
|
if (retValue != null)
|
||||||
{
|
{
|
||||||
s_log.finest("Cache: " + retValue);
|
s_log.finest("Cache: " + retValue);
|
||||||
|
@ -687,8 +687,8 @@ public class MLookupFactory
|
||||||
|
|
||||||
//try cache
|
//try cache
|
||||||
StringBuilder cacheKey = new StringBuilder().append(Env.getAD_Client_ID(ctx)).append("|").append(TableName).append(".").append(KeyColumn);
|
StringBuilder cacheKey = new StringBuilder().append(Env.getAD_Client_ID(ctx)).append("|").append(TableName).append(".").append(KeyColumn);
|
||||||
if (s_cacheRefTable.containsKey(cacheKey))
|
if (s_cacheRefTable.containsKey(cacheKey.toString()))
|
||||||
return s_cacheRefTable.get(cacheKey).cloneIt();
|
return s_cacheRefTable.get(cacheKey.toString()).cloneIt();
|
||||||
|
|
||||||
ArrayList<LookupDisplayColumn> list = getListIdentifiers(TableName);
|
ArrayList<LookupDisplayColumn> list = getListIdentifiers(TableName);
|
||||||
|
|
||||||
|
|
|
@ -308,7 +308,7 @@ public class MMailText extends X_R_MailText
|
||||||
if (m_bpartner != null && m_bpartner.getAD_Language() != null)
|
if (m_bpartner != null && m_bpartner.getAD_Language() != null)
|
||||||
{
|
{
|
||||||
StringBuilder key = new StringBuilder().append(m_bpartner.getAD_Language()).append(get_ID());
|
StringBuilder key = new StringBuilder().append(m_bpartner.getAD_Language()).append(get_ID());
|
||||||
MMailTextTrl trl = s_cacheTrl.get(key);
|
MMailTextTrl trl = s_cacheTrl.get(key.toString());
|
||||||
if (trl == null)
|
if (trl == null)
|
||||||
{
|
{
|
||||||
trl = getTranslation(m_bpartner.getAD_Language());
|
trl = getTranslation(m_bpartner.getAD_Language());
|
||||||
|
|
Loading…
Reference in New Issue