KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > compiere > model > X_C_PaySelectionLine


1 /** Generated Model - DO NOT CHANGE - Copyright (C) 1999-2003 Jorg Janke **/
2 package org.compiere.model;
3 import java.util.*;
4 import java.sql.*;
5 import java.math.*;
6 import java.io.Serializable JavaDoc;
7 import org.compiere.util.*;
8 /** Generated Model for C_PaySelectionLine
9  ** @version $Id: X_C_PaySelectionLine.java,v 1.26 2003/10/31 05:30:53 jjanke Exp $ **/

10 public class X_C_PaySelectionLine extends PO
11 {
12 /** Standard Constructor **/
13 public X_C_PaySelectionLine (Properties ctx, int C_PaySelectionLine_ID)
14 {
15 super (ctx, C_PaySelectionLine_ID);
16 /** if (C_PaySelectionLine_ID == 0)
17 {
18 setC_Invoice_ID (0);
19 setC_PaySelectionLine_ID (0);
20 setC_PaySelection_ID (0);
21 setDifferenceAmt (Env.ZERO);
22 setIsManual (false);
23 setLine (0);
24 setPayAmt (Env.ZERO);
25 setPaymentRule (null);
26 }
27  **/

28 }
29 /** Load Constructor **/
30 public X_C_PaySelectionLine (Properties ctx, ResultSet rs)
31 {
32 super (ctx, rs);
33 }
34 /** Load Meta Data **/
35 protected POInfo initPO (Properties ctx)
36 {
37 int AD_Table_ID = 427;
38 POInfo poi = POInfo.getPOInfo (ctx, AD_Table_ID);
39 return poi;
40 }
41 public String JavaDoc toString()
42 {
43 StringBuffer JavaDoc sb = new StringBuffer JavaDoc ("X_C_PaySelectionLine[").append(getID()).append("]");
44 return sb.toString();
45 }
46 public void setC_Invoice_ID (int C_Invoice_ID)
47 {
48 setValue ("C_Invoice_ID", new Integer JavaDoc(C_Invoice_ID));
49 }
50 public int getC_Invoice_ID()
51 {
52 Integer JavaDoc ii = (Integer JavaDoc)getValue("C_Invoice_ID");
53 if (ii == null) return 0;
54 return ii.intValue();
55 }
56 public void setC_PaySelectionCheck_ID (int C_PaySelectionCheck_ID)
57 {
58 if (C_PaySelectionCheck_ID == 0) setValue ("C_PaySelectionCheck_ID", null);
59  else
60 setValue ("C_PaySelectionCheck_ID", new Integer JavaDoc(C_PaySelectionCheck_ID));
61 }
62 public int getC_PaySelectionCheck_ID()
63 {
64 Integer JavaDoc ii = (Integer JavaDoc)getValue("C_PaySelectionCheck_ID");
65 if (ii == null) return 0;
66 return ii.intValue();
67 }
68 void setC_PaySelectionLine_ID (int C_PaySelectionLine_ID)
69 {
70 setValueNoCheck ("C_PaySelectionLine_ID", new Integer JavaDoc(C_PaySelectionLine_ID));
71 }
72 public int getC_PaySelectionLine_ID()
73 {
74 Integer JavaDoc ii = (Integer JavaDoc)getValue("C_PaySelectionLine_ID");
75 if (ii == null) return 0;
76 return ii.intValue();
77 }
78 void setC_PaySelection_ID (int C_PaySelection_ID)
79 {
80 setValueNoCheck ("C_PaySelection_ID", new Integer JavaDoc(C_PaySelection_ID));
81 }
82 public int getC_PaySelection_ID()
83 {
84 Integer JavaDoc ii = (Integer JavaDoc)getValue("C_PaySelection_ID");
85 if (ii == null) return 0;
86 return ii.intValue();
87 }
88 public void setDescription (String JavaDoc Description)
89 {
90 setValue ("Description", Description);
91 }
92 public String JavaDoc getDescription()
93 {
94 return (String JavaDoc)getValue("Description");
95 }
96 void setDifferenceAmt (BigDecimal DifferenceAmt)
97 {
98 if (DifferenceAmt == null) throw new IllegalArgumentException JavaDoc ("DifferenceAmt is mandatory");
99 setValueNoCheck ("DifferenceAmt", DifferenceAmt);
100 }
101 public BigDecimal getDifferenceAmt()
102 {
103 BigDecimal bd = (BigDecimal)getValue("DifferenceAmt");
104 if (bd == null) return Env.ZERO;
105 return bd;
106 }
107 public void setIsManual (boolean IsManual)
108 {
109 setValue ("IsManual", new Boolean JavaDoc(IsManual));
110 }
111 public boolean isManual()
112 {
113 Boolean JavaDoc bb = (Boolean JavaDoc)getValue("IsManual");
114 if (bb != null) return bb.booleanValue();
115 return false;
116 }
117 public void setLine (int Line)
118 {
119 setValue ("Line", new Integer JavaDoc(Line));
120 }
121 public int getLine()
122 {
123 Integer JavaDoc ii = (Integer JavaDoc)getValue("Line");
124 if (ii == null) return 0;
125 return ii.intValue();
126 }
127 public void setPayAmt (BigDecimal PayAmt)
128 {
129 if (PayAmt == null) throw new IllegalArgumentException JavaDoc ("PayAmt is mandatory");
130 setValue ("PayAmt", PayAmt);
131 }
132 public BigDecimal getPayAmt()
133 {
134 BigDecimal bd = (BigDecimal)getValue("PayAmt");
135 if (bd == null) return Env.ZERO;
136 return bd;
137 }
138 public static final String JavaDoc PAYMENTRULE_Cash = "B";
139 public static final String JavaDoc PAYMENTRULE_CreditCard = "K";
140 public static final String JavaDoc PAYMENTRULE_TransferACH = "T";
141 public static final String JavaDoc PAYMENTRULE_Check = "S";
142 public static final String JavaDoc PAYMENTRULE_OnCredit = "P";
143 public void setPaymentRule (String JavaDoc PaymentRule)
144 {
145 if (PaymentRule.equals("B") || PaymentRule.equals("K") || PaymentRule.equals("T") || PaymentRule.equals("S") || PaymentRule.equals("P"));
146  else throw new IllegalArgumentException JavaDoc ("PaymentRule Invalid value - Reference_ID=195 - B - K - T - S - P");
147 if (PaymentRule == null) throw new IllegalArgumentException JavaDoc ("PaymentRule is mandatory");
148 setValue ("PaymentRule", PaymentRule);
149 }
150 public String JavaDoc getPaymentRule()
151 {
152 return (String JavaDoc)getValue("PaymentRule");
153 }
154 }
155
Popular Tags