IDEMPIERE-455 Discover and fix FindBugs problems / Generate serialVersionUID instead of the default 1L

This commit is contained in:
Richard Morales 2012-12-12 17:37:18 -05:00
parent 624d5862e2
commit cbe8d69e30
35 changed files with 149 additions and 36 deletions

View File

@ -21,7 +21,12 @@ import org.compiere.util.TimeUtil;
*/ */
public class MAssetAcct extends X_A_Asset_Acct public class MAssetAcct extends X_A_Asset_Acct
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -3919172418904053712L;
/** /**
* DO NOT USE DIRECTLY * DO NOT USE DIRECTLY

View File

@ -35,8 +35,11 @@ import org.idempiere.fa.util.POCacheLocal;
public class MAssetAddition extends X_A_Asset_Addition public class MAssetAddition extends X_A_Asset_Addition
implements DocAction implements DocAction
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = 5977180589101094202L;
/** Static Logger */ /** Static Logger */
private static CLogger s_log = CLogger.getCLogger(MAssetAddition.class); private static CLogger s_log = CLogger.getCLogger(MAssetAddition.class);

View File

@ -12,8 +12,11 @@ import org.compiere.util.DB;
*/ */
public class MAssetGroup extends X_A_Asset_Group public class MAssetGroup extends X_A_Asset_Group
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -173157506404569463L;
/** Cache: ID -> MAssetGroup */ /** Cache: ID -> MAssetGroup */
private static CCache<Integer, MAssetGroup> s_cache = new CCache<Integer, MAssetGroup>(Table_Name, 10, 0); private static CCache<Integer, MAssetGroup> s_cache = new CCache<Integer, MAssetGroup>(Table_Name, 10, 0);

View File

@ -16,7 +16,11 @@ import org.idempiere.fa.feature.UseLifeImpl;
public class MAssetGroupAcct extends X_A_Asset_Group_Acct public class MAssetGroupAcct extends X_A_Asset_Group_Acct
implements UseLife implements UseLife
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -3458020679308192943L;
/** /**
* Get Asset Group Accountings for given group * Get Asset Group Accountings for given group

View File

@ -12,7 +12,11 @@ import org.compiere.model.Query;
*/ */
public class MAssetProduct extends X_A_Asset_Product public class MAssetProduct extends X_A_Asset_Product
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = 2459915999284269350L;
/** Standard Constructor */ /** Standard Constructor */
public MAssetProduct (Properties ctx, int A_Asset_Product_ID, String trxName) public MAssetProduct (Properties ctx, int A_Asset_Product_ID, String trxName)

View File

@ -27,8 +27,11 @@ import org.compiere.util.TimeUtil;
public class MAssetReval extends X_A_Asset_Reval public class MAssetReval extends X_A_Asset_Reval
implements DocAction implements DocAction
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -3937514008250840440L;
private boolean m_justPrepared = false; private boolean m_justPrepared = false;
public MAssetReval(Properties ctx, int X_A_Asset_Reval_ID, String trxName) public MAssetReval(Properties ctx, int X_A_Asset_Reval_ID, String trxName)

View File

@ -38,7 +38,10 @@ import org.idempiere.fa.exceptions.AssetAlreadyDepreciatedException;
public class MAssetTransfer extends X_A_Asset_Transfer public class MAssetTransfer extends X_A_Asset_Transfer
implements DocAction implements DocAction
{ {
private static final long serialVersionUID = 1L; /**
*
*/
private static final long serialVersionUID = 2997284714883099922L;
/** Just Prepared Flag */ /** Just Prepared Flag */
private boolean m_justPrepared = false; private boolean m_justPrepared = false;

View File

@ -20,7 +20,11 @@ import org.idempiere.fa.exceptions.AssetNotSupportedException;
*/ */
public class MDepreciation extends X_A_Depreciation public class MDepreciation extends X_A_Depreciation
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -632058079835100100L;
/** Standard Constructor */ /** Standard Constructor */
public MDepreciation (Properties ctx, int A_Depreciation_ID, String trxName) public MDepreciation (Properties ctx, int A_Depreciation_ID, String trxName)

View File

@ -28,7 +28,12 @@ import org.idempiere.fa.exceptions.AssetException;
public class MDepreciationEntry extends X_A_Depreciation_Entry public class MDepreciationEntry extends X_A_Depreciation_Entry
implements DocAction implements DocAction
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = 6631244784741228058L;
/** Standard Constructor */ /** Standard Constructor */
public MDepreciationEntry(Properties ctx, int A_Depreciation_Entry_ID, String trxName) public MDepreciationEntry(Properties ctx, int A_Depreciation_Entry_ID, String trxName)

View File

@ -21,8 +21,11 @@ import org.idempiere.fa.exceptions.AssetNotActiveException;
public class MDepreciationExp extends X_A_Depreciation_Exp public class MDepreciationExp extends X_A_Depreciation_Exp
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = 6731366890875525147L;
private static CLogger s_log = CLogger.getCLogger(MDepreciationExp.class); private static CLogger s_log = CLogger.getCLogger(MDepreciationExp.class);
private CLogger log = CLogger.getCLogger(this.getClass()); private CLogger log = CLogger.getCLogger(this.getClass());

View File

@ -23,8 +23,11 @@ import org.compiere.util.Util;
*/ */
public class MIFixedAsset extends X_I_FixedAsset public class MIFixedAsset extends X_I_FixedAsset
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -6394518107160329652L;
/** Default depreciation method */ /** Default depreciation method */
private static final String s_defaultDepreciationType = "SL"; private static final String s_defaultDepreciationType = "SL";

View File

@ -29,7 +29,11 @@ import org.compiere.util.Env;
*/ */
public class NoCurrencyConversionException extends AdempiereException public class NoCurrencyConversionException extends AdempiereException
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = 1593966161685137709L;
/** /**
* *

View File

@ -11,7 +11,11 @@ package org.idempiere.fa.exceptions;
*/ */
public class AssetAlreadyDepreciatedException extends AssetException public class AssetAlreadyDepreciatedException extends AssetException
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -2531645693567226455L;
public AssetAlreadyDepreciatedException() public AssetAlreadyDepreciatedException()
{ {

View File

@ -10,7 +10,11 @@ package org.idempiere.fa.exceptions;
*/ */
public class AssetCheckDocumentException extends AssetException public class AssetCheckDocumentException extends AssetException
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -8096988198983528889L;
public AssetCheckDocumentException(String additionalMessage) public AssetCheckDocumentException(String additionalMessage)
{ {

View File

@ -11,7 +11,11 @@ import org.adempiere.exceptions.AdempiereException;
*/ */
public class AssetException extends AdempiereException public class AssetException extends AdempiereException
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -2163958702697438015L;
public AssetException() public AssetException()
{ {

View File

@ -9,7 +9,11 @@ package org.idempiere.fa.exceptions;
* *
*/ */
public class AssetInvoiceWithMixedLines_LRO extends AssetException { public class AssetInvoiceWithMixedLines_LRO extends AssetException {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = 7477049497754422353L;
public AssetInvoiceWithMixedLines_LRO() { public AssetInvoiceWithMixedLines_LRO() {
super("No new bills that contain both fixed and normal products"); super("No new bills that contain both fixed and normal products");

View File

@ -9,7 +9,11 @@ package org.idempiere.fa.exceptions;
*/ */
public class AssetNotActiveException extends AssetException public class AssetNotActiveException extends AssetException
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -958395266586669844L;
public AssetNotActiveException(int A_Asset_ID) public AssetNotActiveException(int A_Asset_ID)
{ {

View File

@ -11,7 +11,11 @@ package org.idempiere.fa.exceptions;
*/ */
public class AssetNotImplementedException extends AssetException public class AssetNotImplementedException extends AssetException
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -7015542410574849684L;
public AssetNotImplementedException(String additionalMessage) public AssetNotImplementedException(String additionalMessage)
{ {

View File

@ -9,7 +9,11 @@ package org.idempiere.fa.exceptions;
*/ */
public class AssetNotSupportedException extends AssetException public class AssetNotSupportedException extends AssetException
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -9182818872935345775L;
public AssetNotSupportedException (String funcName, String actualValue) public AssetNotSupportedException (String funcName, String actualValue)
{ {

View File

@ -11,7 +11,11 @@ import org.compiere.model.MProduct;
*/ */
public class AssetProductStockedException extends AssetException public class AssetProductStockedException extends AssetException
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = 229246069558704158L;
public AssetProductStockedException(MProduct product) public AssetProductStockedException(MProduct product)
{ {

View File

@ -11,7 +11,11 @@ import org.compiere.util.Util;
*/ */
public class AssetStatusChangedException extends AssetException public class AssetStatusChangedException extends AssetException
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -2015948851153849647L;
public AssetStatusChangedException() public AssetStatusChangedException()
{ {

View File

@ -9,8 +9,12 @@ package org.idempiere.fa.exceptions;
*/ */
public class DepreciationNoInPeriodException extends AssetException public class DepreciationNoInPeriodException extends AssetException
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -6201871355182540721L;
public DepreciationNoInPeriodException(int A_Asset_ID, int Workfile_Period_ID, int DepExp_Period_ID) public DepreciationNoInPeriodException(int A_Asset_ID, int Workfile_Period_ID, int DepExp_Period_ID)
{ {
super("Registration is not in balance (ID Asset="+A_Asset_ID super("Registration is not in balance (ID Asset="+A_Asset_ID

View File

@ -252,7 +252,12 @@ public class VTreeBOM extends CPanel implements FormPanel, ActionListener, TreeS
DisplayType.Search, language, MProduct.COLUMNNAME_M_Product_ID, 0, false, DisplayType.Search, language, MProduct.COLUMNNAME_M_Product_ID, 0, false,
" M_Product.IsSummary = 'N'"); " M_Product.IsSummary = 'N'");
fieldProduct = new VLookup ("M_Product_ID", false, false, true, m_fieldProduct) { fieldProduct = new VLookup ("M_Product_ID", false, false, true, m_fieldProduct) {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = 1084743143950828526L;
public void setValue(Object value) { public void setValue(Object value) {
super.setValue(value); super.setValue(value);
} }

View File

@ -38,8 +38,11 @@ import org.compiere.util.TrxRunnable;
public class VCreateFromDialog extends CDialog implements ActionListener, TableModelListener public class VCreateFromDialog extends CDialog implements ActionListener, TableModelListener
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -8242250391030501785L;
private CreateFrom createFrom; private CreateFrom createFrom;
private int windowNo; private int windowNo;

View File

@ -45,7 +45,6 @@ import org.compiere.util.Msg;
public class VCreateFromInvoiceUI extends CreateFromInvoice implements ActionListener, VetoableChangeListener public class VCreateFromInvoiceUI extends CreateFromInvoice implements ActionListener, VetoableChangeListener
{ {
private static final long serialVersionUID = 1L;
private VCreateFromDialog dialog; private VCreateFromDialog dialog;

View File

@ -39,7 +39,6 @@ import org.compiere.util.Msg;
public class VCreateFromRMAUI extends CreateFromRMA implements VetoableChangeListener public class VCreateFromRMAUI extends CreateFromRMA implements VetoableChangeListener
{ {
private static final long serialVersionUID = 1L;
private VCreateFromDialog dialog; private VCreateFromDialog dialog;

View File

@ -55,7 +55,6 @@ import org.compiere.util.Msg;
public class VCreateFromStatementUI extends CreateFromStatement implements ActionListener public class VCreateFromStatementUI extends CreateFromStatement implements ActionListener
{ {
private static final long serialVersionUID = 1L;
private VCreateFromDialog dialog; private VCreateFromDialog dialog;

View File

@ -36,10 +36,11 @@ import org.compiere.model.MTreeNode;
*/ */
public class VTreeTransferHandler extends TransferHandler { public class VTreeTransferHandler extends TransferHandler {
/** /**
* *
*/ */
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 2799737958477528717L;
public int getSourceActions(JComponent c) { public int getSourceActions(JComponent c) {
return TransferHandler.MOVE; return TransferHandler.MOVE;

View File

@ -39,8 +39,11 @@ import org.zkoss.zul.Separator;
public class WCreateFromWindow extends Window implements EventListener<Event>, WTableModelListener, DialogEvents public class WCreateFromWindow extends Window implements EventListener<Event>, WTableModelListener, DialogEvents
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -3703236565441597403L;
private CreateFrom createFrom; private CreateFrom createFrom;
private int windowNo; private int windowNo;

View File

@ -65,8 +65,11 @@ import org.zkoss.zul.Toolbarbutton;
* *
*/ */
public class CalendarWindow extends Window implements EventListener<Event> { public class CalendarWindow extends Window implements EventListener<Event> {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = 5620139733919619691L;
private Calendars calendars; private Calendars calendars;
private SimpleCalendarModel scm; private SimpleCalendarModel scm;
private Toolbarbutton btnRefresh; private Toolbarbutton btnRefresh;

View File

@ -47,8 +47,11 @@ import org.zkoss.zul.Toolbarbutton;
*/ */
public class DPCalendar extends DashboardPanel implements EventListener<Event> { public class DPCalendar extends DashboardPanel implements EventListener<Event> {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -224914882522997787L;
private Calendars calendars; private Calendars calendars;
private SimpleCalendarModel scm; private SimpleCalendarModel scm;
private Toolbarbutton btnCal, btnRefresh; private Toolbarbutton btnCal, btnRefresh;

View File

@ -37,8 +37,11 @@ import org.zkoss.zul.South;
* *
*/ */
public class EventWindow extends Window implements EventListener<Event> { public class EventWindow extends Window implements EventListener<Event> {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = 4758066526040260586L;
private DatetimeBox dtBeginDate, dtEndDate; private DatetimeBox dtBeginDate, dtEndDate;
private Textbox txtContent, txtHeaderColor, txtContentColor; private Textbox txtContent, txtHeaderColor, txtContentColor;
private ConfirmPanel confirmPanel; private ConfirmPanel confirmPanel;

View File

@ -53,8 +53,12 @@ import org.zkoss.zul.Timebox;
* *
*/ */
public class RequestWindow extends Window implements EventListener<Event> { public class RequestWindow extends Window implements EventListener<Event> {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = 7757368164776005797L;
private static CLogger log = CLogger.getCLogger(RequestWindow.class); private static CLogger log = CLogger.getCLogger(RequestWindow.class);
/** Read Only */ /** Read Only */

View File

@ -2,7 +2,11 @@ package org.adempiere.webui.panel;
public class CustomForm extends ADForm public class CustomForm extends ADForm
{ {
private static final long serialVersionUID = 1L;
/**
*
*/
private static final long serialVersionUID = -8498084996736578534L;
@Override @Override
protected void initForm() protected void initForm()

View File

@ -45,9 +45,12 @@ import org.adempiere.util.ServerContextURLHandler;
*/ */
public class WebUIServlet extends DHtmlLayoutServlet public class WebUIServlet extends DHtmlLayoutServlet
{ {
private static final long serialVersionUID = 1L;
/** Logger for the class * */ /**
*
*/
private static final long serialVersionUID = -5625631664012999381L;
/** Logger for the class * */
private static CLogger logger; private static CLogger logger;
public void init(ServletConfig servletConfig) throws ServletException public void init(ServletConfig servletConfig) throws ServletException