View Javadoc

1   /*
2    * SymmetricDS is an open source database synchronization solution.
3    *   
4    * Copyright (C) Chris Henson <chenson42@users.sourceforge.net>
5    *
6    * This library is free software; you can redistribute it and/or
7    * modify it under the terms of the GNU Lesser General Public
8    * License as published by the Free Software Foundation; either
9    * version 3 of the License, or (at your option) any later version.
10   *
11   * This library is distributed in the hope that it will be useful,
12   * but WITHOUT ANY WARRANTY; without even the implied warranty of
13   * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14   * Lesser General Public License for more details.
15   *
16   * You should have received a copy of the GNU Lesser General Public
17   * License along with this library; if not, see
18   * <http://www.gnu.org/licenses/>.
19   */
20  
21  package org.jumpmind.symmetric.model;
22  
23  public class BatchInfo {
24  
25      private long batchId;
26  
27      private String nodeId;
28  
29      private boolean isOk;
30  
31      private long errorLine;
32  
33      private long networkMillis;
34  
35      private long filterMillis;
36  
37      private long databaseMillis;
38  
39      private long byteCount;
40  
41      private String sqlState;
42  
43      private int sqlCode;
44  
45      private String sqlMessage;
46  
47      public BatchInfo(long batchId) {
48          this.batchId = batchId;
49          isOk = true;
50      }
51  
52      public BatchInfo(long batchId, long errorLineNumber) {
53          this.batchId = batchId;
54          isOk = false;
55          errorLine = errorLineNumber;
56      }
57  
58      public long getBatchId() {
59          return batchId;
60      }
61  
62      public long getErrorLine() {
63          return errorLine;
64      }
65  
66      public boolean isOk() {
67          return isOk;
68      }
69  
70      public void setBatchId(long batchId) {
71          this.batchId = batchId;
72      }
73  
74      public void setErrorLine(long errorLine) {
75          this.errorLine = errorLine;
76      }
77  
78      public void setOk(boolean isOk) {
79          this.isOk = isOk;
80      }
81  
82      public long getByteCount() {
83          return byteCount;
84      }
85  
86      public void setByteCount(long byteCount) {
87          this.byteCount = byteCount;
88      }
89  
90      public long getDatabaseMillis() {
91          return databaseMillis;
92      }
93  
94      public void setDatabaseMillis(long databaseMillis) {
95          this.databaseMillis = databaseMillis;
96      }
97  
98      public long getFilterMillis() {
99          return filterMillis;
100     }
101 
102     public void setFilterMillis(long filterMillis) {
103         this.filterMillis = filterMillis;
104     }
105 
106     public long getNetworkMillis() {
107         return networkMillis;
108     }
109 
110     public void setNetworkMillis(long networkMillis) {
111         this.networkMillis = networkMillis;
112     }
113 
114     public int getSqlCode() {
115         return sqlCode;
116     }
117 
118     public void setSqlCode(int sqlCode) {
119         this.sqlCode = sqlCode;
120     }
121 
122     public String getSqlMessage() {
123         return sqlMessage;
124     }
125 
126     public void setSqlMessage(String sqlMessage) {
127         this.sqlMessage = sqlMessage;
128     }
129 
130     public String getSqlState() {
131         return sqlState;
132     }
133 
134     public void setSqlState(String sqlState) {
135         this.sqlState = sqlState;
136     }
137 
138     public String getNodeId() {
139         return nodeId;
140     }
141 
142     public void setNodeId(String nodeId) {
143         this.nodeId = nodeId;
144     }
145 
146 }