X_M_Locator.java
| Index Score | ||
|---|---|---|
![]() |
![]() |
org.compiere.model |
![]() |
![]() |
Compiere |
View: Reasons, Metrics, Source Code
These are the metrics that contribute to the Enerjy Score for this file, ranked by impact. So the metrics listed at the top influence the score to a greater extent that the metrics listed at the bottom.
/******************************************************************************
* Product: Compiere ERP & CRM Smart Business Solution *
* Copyright (C) 1999-2007 ComPiere, Inc. All Rights Reserved. *
* This program is free software, you can redistribute it and/or modify it *
* under the terms version 2 of the GNU General Public License as published *
* by the Free Software Foundation. This program is distributed in the hope *
* that it will be useful, but WITHOUT ANY WARRANTY, without even the implied *
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. *
* See the GNU General Public License for more details. *
* You should have received a copy of the GNU General Public License along *
* with this program, if not, write to the Free Software Foundation, Inc., *
* 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. *
* For the text or an alternative of this public license, you may reach us *
* ComPiere, Inc., 3600 Bridge Parkway #102, Redwood City, CA 94065, USA *
* or via info@compiere.org or http://www.compiere.org/license.html *
*****************************************************************************/
package org.compiere.model;
/** Generated Model - DO NOT CHANGE */
import java.sql.*;
import java.math.*;
import org.compiere.framework.*;
import org.compiere.util.*;
/** Generated Model for M_Locator
* @author Jorg Janke (generated)
* @version Release 3.1.0 - $Id$ */
public class X_M_Locator extends PO
{
/** Standard Constructor
@param ctx context
@param M_Locator_ID id
@param trxName transaction
*/
public X_M_Locator (Ctx ctx, int M_Locator_ID, String trxName)
{
super (ctx, M_Locator_ID, trxName);
/** if (M_Locator_ID == 0)
{
setIsAvailableForAllocation (true); // Y
setIsAvailableToPromise (true); // Y
setIsDefault (false);
setM_Locator_ID (0);
setM_Warehouse_ID (0);
setPickingSeqNo (0);
setPriorityNo (0); // 50
setPutawaySeqNo (0);
setValue (null);
}
*/
}
/** Load Constructor
@param ctx context
@param rs result set
@param trxName transaction
*/
public X_M_Locator (Ctx ctx, ResultSet rs, String trxName)
{
super (ctx, rs, trxName);
}
/** Serial Version No */
static final long serialVersionUID = 27495261242789L;
/** Last Updated Timestamp 2008-06-10 15:12:06.0 */
public static final long updatedMS = 1213135926000L;
/** AD_Table_ID=207 */
public static final int Table_ID=207;
/** TableName=M_Locator */
public static final String Table_Name="M_Locator";
protected static KeyNamePair Model = new KeyNamePair(Table_ID,"M_Locator");
protected BigDecimal accessLevel = new BigDecimal(7);
/** AccessLevel
@return 7 - System - Client - Org
*/
protected int get_AccessLevel()
{
return accessLevel.intValue();
}
/** Load Meta Data
@param ctx context
@return PO Info
*/
protected POInfo initPO (Ctx ctx)
{
POInfo poi = POInfo.getPOInfo (ctx, Table_ID);
return poi;
}
/** Info
@return info
*/
public String toString()
{
StringBuffer sb = new StringBuffer ("X_M_Locator[").append(get_ID()).append("]");
return sb.toString();
}
/** Set Bin.
@param Bin Locator Bin segment */
public void setBin (String Bin)
{
int length = p_info.getFieldLength("Bin");
if (Bin != null && Bin.length() > length)
{
log.warning("Length > " + length + " - truncated");
Bin = Bin.substring(0,length);
}
set_Value ("Bin", Bin);
}
/** Get Bin.
@return Locator Bin segment */
public String getBin()
{
return (String)get_Value("Bin");
}
/** Set Available For Allocation.
@param IsAvailableForAllocation Onhand in locator is available for allocation */
public void setIsAvailableForAllocation (boolean IsAvailableForAllocation)
{
set_Value ("IsAvailableForAllocation", new Boolean(IsAvailableForAllocation));
}
/** Get Available For Allocation.
@return Onhand in locator is available for allocation */
public boolean isAvailableForAllocation()
{
Object oo = get_Value("IsAvailableForAllocation");
if (oo != null)
{
if (oo instanceof Boolean) return ((Boolean)oo).booleanValue();
return "Y".equals(oo);
}
return false;
}
/** Set Available To Promise.
@param IsAvailableToPromise Onhand is available to promise */
public void setIsAvailableToPromise (boolean IsAvailableToPromise)
{
set_Value ("IsAvailableToPromise", new Boolean(IsAvailableToPromise));
}
/** Get Available To Promise.
@return Onhand is available to promise */
public boolean isAvailableToPromise()
{
Object oo = get_Value("IsAvailableToPromise");
if (oo != null)
{
if (oo instanceof Boolean) return ((Boolean)oo).booleanValue();
return "Y".equals(oo);
}
return false;
}
/** Set Default.
@param IsDefault Default value */
public void setIsDefault (boolean IsDefault)
{
set_Value ("IsDefault", new Boolean(IsDefault));
}
/** Get Default.
@return Default value */
public boolean isDefault()
{
Object oo = get_Value("IsDefault");
if (oo != null)
{
if (oo instanceof Boolean) return ((Boolean)oo).booleanValue();
return "Y".equals(oo);
}
return false;
}
/** Set Locator.
@param LocatorCombination Delimited combination of locator segments */
public void setLocatorCombination (String LocatorCombination)
{
int length = p_info.getFieldLength("LocatorCombination");
if (LocatorCombination != null && LocatorCombination.length() > length)
{
log.warning("Length > " + length + " - truncated");
LocatorCombination = LocatorCombination.substring(0,length);
}
set_Value ("LocatorCombination", LocatorCombination);
}
/** Get Locator.
@return Delimited combination of locator segments */
public String getLocatorCombination()
{
return (String)get_Value("LocatorCombination");
}
/** Set Locator.
@param M_Locator_ID Warehouse Locator */
public void setM_Locator_ID (int M_Locator_ID)
{
if (M_Locator_ID < 1) throw new IllegalArgumentException ("M_Locator_ID is mandatory.");
set_ValueNoCheck ("M_Locator_ID", new Integer(M_Locator_ID));
}
/** Get Locator.
@return Warehouse Locator */
public int getM_Locator_ID()
{
Integer ii = (Integer)get_Value("M_Locator_ID");
if (ii == null) return 0;
return ii.intValue();
}
/** Set Warehouse.
@param M_Warehouse_ID Storage Warehouse and Service Point */
public void setM_Warehouse_ID (int M_Warehouse_ID)
{
if (M_Warehouse_ID < 1) throw new IllegalArgumentException ("M_Warehouse_ID is mandatory.");
set_ValueNoCheck ("M_Warehouse_ID", new Integer(M_Warehouse_ID));
}
/** Get Warehouse.
@return Storage Warehouse and Service Point */
public int getM_Warehouse_ID()
{
Integer ii = (Integer)get_Value("M_Warehouse_ID");
if (ii == null) return 0;
return ii.intValue();
}
/** Get Record ID/ColumnName
@return ID/ColumnName pair */
public KeyNamePair getKeyNamePair()
{
return new KeyNamePair(get_ID(), String.valueOf(getM_Warehouse_ID()));
}
/** Set Max Stocking Quantity.
@param MaxQuantity Maximum stocking capacity of the locator in units */
public void setMaxQuantity (BigDecimal MaxQuantity)
{
set_Value ("MaxQuantity", MaxQuantity);
}
/** Get Max Stocking Quantity.
@return Maximum stocking capacity of the locator in units */
public BigDecimal getMaxQuantity()
{
BigDecimal bd = (BigDecimal)get_Value("MaxQuantity");
if (bd == null) return Env.ZERO;
return bd;
}
/** Set Min Stocking Quantity.
@param MinQuantity Minimum stocking quantity of locator in units */
public void setMinQuantity (BigDecimal MinQuantity)
{
set_Value ("MinQuantity", MinQuantity);
}
/** Get Min Stocking Quantity.
@return Minimum stocking quantity of locator in units */
public BigDecimal getMinQuantity()
{
BigDecimal bd = (BigDecimal)get_Value("MinQuantity");
if (bd == null) return Env.ZERO;
return bd;
}
/** Set Picking Sequence No.
@param PickingSeqNo Locator Picking Sequence Number */
public void setPickingSeqNo (int PickingSeqNo)
{
set_Value ("PickingSeqNo", new Integer(PickingSeqNo));
}
/** Get Picking Sequence No.
@return Locator Picking Sequence Number */
public int getPickingSeqNo()
{
Integer ii = (Integer)get_Value("PickingSeqNo");
if (ii == null) return 0;
return ii.intValue();
}
/** Picking_UOM_ID AD_Reference_ID=114 */
public static final int PICKING_UOM_ID_AD_Reference_ID=114;
/** Set Picking UOM.
@param Picking_UOM_ID Picking UOM of locator */
public void setPicking_UOM_ID (int Picking_UOM_ID)
{
if (Picking_UOM_ID <= 0) set_Value ("Picking_UOM_ID", null);
else
set_Value ("Picking_UOM_ID", new Integer(Picking_UOM_ID));
}
/** Get Picking UOM.
@return Picking UOM of locator */
public int getPicking_UOM_ID()
{
Integer ii = (Integer)get_Value("Picking_UOM_ID");
if (ii == null) return 0;
return ii.intValue();
}
/** Set Position.
@param Position Locator Position segment */
public void setPosition (String Position)
{
int length = p_info.getFieldLength("Position");
if (Position != null && Position.length() > length)
{
log.warning("Length > " + length + " - truncated");
Position = Position.substring(0,length);
}
set_Value ("Position", Position);
}
/** Get Position.
@return Locator Position segment */
public String getPosition()
{
return (String)get_Value("Position");
}
/** Set Relative Priority.
@param PriorityNo Where inventory should be picked from first */
public void setPriorityNo (int PriorityNo)
{
set_Value ("PriorityNo", new Integer(PriorityNo));
}
/** Get Relative Priority.
@return Where inventory should be picked from first */
public int getPriorityNo()
{
Integer ii = (Integer)get_Value("PriorityNo");
if (ii == null) return 0;
return ii.intValue();
}
/** Set Putaway Sequence No.
@param PutawaySeqNo Putaway Sequence Number of locator */
public void setPutawaySeqNo (int PutawaySeqNo)
{
set_Value ("PutawaySeqNo", new Integer(PutawaySeqNo));
}
/** Get Putaway Sequence No.
@return Putaway Sequence Number of locator */
public int getPutawaySeqNo()
{
Integer ii = (Integer)get_Value("PutawaySeqNo");
if (ii == null) return 0;
return ii.intValue();
}
/** Stocking_UOM_ID AD_Reference_ID=114 */
public static final int STOCKING_UOM_ID_AD_Reference_ID=114;
/** Set Stocking UOM.
@param Stocking_UOM_ID Stocking UOM of locator */
public void setStocking_UOM_ID (int Stocking_UOM_ID)
{
if (Stocking_UOM_ID <= 0) set_Value ("Stocking_UOM_ID", null);
else
set_Value ("Stocking_UOM_ID", new Integer(Stocking_UOM_ID));
}
/** Get Stocking UOM.
@return Stocking UOM of locator */
public int getStocking_UOM_ID()
{
Integer ii = (Integer)get_Value("Stocking_UOM_ID");
if (ii == null) return 0;
return ii.intValue();
}
/** Set Search Key.
@param Value Search key for the record in the format required - must be unique */
public void setValue (String Value)
{
if (Value == null) throw new IllegalArgumentException ("Value is mandatory.");
int length = p_info.getFieldLength("Value");
if (Value.length() > length)
{
log.warning("Length > " + length + " - truncated");
Value = Value.substring(0,length);
}
set_Value ("Value", Value);
}
/** Get Search Key.
@return Search key for the record in the format required - must be unique */
public String getValue()
{
return (String)get_Value("Value");
}
/** Set Aisle.
@param X Locator Aisle segment */
public void setX (String X)
{
int length = p_info.getFieldLength("X");
if (X != null && X.length() > length)
{
log.warning("Length > " + length + " - truncated");
X = X.substring(0,length);
}
set_Value ("X", X);
}
/** Get Aisle.
@return Locator Aisle segment */
public String getX()
{
return (String)get_Value("X");
}
/** Set Bay.
@param Y Locator Bay segment */
public void setY (String Y)
{
int length = p_info.getFieldLength("Y");
if (Y != null && Y.length() > length)
{
log.warning("Length > " + length + " - truncated");
Y = Y.substring(0,length);
}
set_Value ("Y", Y);
}
/** Get Bay.
@return Locator Bay segment */
public String getY()
{
return (String)get_Value("Y");
}
/** Set Row.
@param Z Row segment of locator */
public void setZ (String Z)
{
int length = p_info.getFieldLength("Z");
if (Z != null && Z.length() > length)
{
log.warning("Length > " + length + " - truncated");
Z = Z.substring(0,length);
}
set_Value ("Z", Z);
}
/** Get Row.
@return Row segment of locator */
public String getZ()
{
return (String)get_Value("Z");
}
}
The table below shows all metrics for X_M_Locator.java.




