View Javadoc

1   /*
2    * SymmetricDS is an open source database synchronization solution.
3    *   
4    * Copyright (C) Chris Henson <chenson42@users.sourceforge.net>,
5    *               Eric Long <erilong@users.sourceforge.net>,
6    *               Keith Naas <knaas@users.sourceforge.net>
7    *               
8    *
9    * This library is free software; you can redistribute it and/or
10   * modify it under the terms of the GNU Lesser General Public
11   * License as published by the Free Software Foundation; either
12   * version 3 of the License, or (at your option) any later version.
13   *
14   * This library is distributed in the hope that it will be useful,
15   * but WITHOUT ANY WARRANTY; without even the implied warranty of
16   * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
17   * Lesser General Public License for more details.
18   *
19   * You should have received a copy of the GNU Lesser General Public
20   * License along with this library; if not, see
21   * <http://www.gnu.org/licenses/>.
22   */
23  package org.jumpmind.symmetric.service.mock;
24  
25  import java.io.BufferedWriter;
26  import java.io.IOException;
27  import java.io.OutputStream;
28  
29  import org.jumpmind.symmetric.extract.DataExtractorContext;
30  import org.jumpmind.symmetric.extract.IExtractorFilter;
31  import org.jumpmind.symmetric.model.Node;
32  import org.jumpmind.symmetric.model.OutgoingBatch;
33  import org.jumpmind.symmetric.model.Trigger;
34  import org.jumpmind.symmetric.service.IDataExtractorService;
35  import org.jumpmind.symmetric.service.IExtractListener;
36  import org.jumpmind.symmetric.transport.IOutgoingTransport;
37  
38  public class MockDataExtractorService implements IDataExtractorService {
39      
40      public void extractConfiguration(Node node, BufferedWriter writer, DataExtractorContext ctx) throws IOException {
41      }
42      
43      public void extractConfigurationStandalone(Node node, BufferedWriter out) throws IOException {
44      }
45  
46      public boolean extract(Node node, IOutgoingTransport transport) throws Exception {
47          return false;
48      }
49  
50      public boolean extract(Node node, IExtractListener handler) throws Exception {
51          return false;
52      }
53  
54      public boolean extractBatchRange(IOutgoingTransport transport, String startBatchId, String endBatchId)
55              throws Exception {
56          return false;
57      }
58  
59      public boolean extractBatchRange(IExtractListener handler, String startBatchId, String endBatchId) throws Exception {
60          return false;
61      }
62  
63      public OutgoingBatch extractInitialLoadFor(Node node, Trigger config, BufferedWriter writer) {
64          return null;
65      }
66  
67      public void extractInitialLoadWithinBatchFor(Node node, Trigger trigger, BufferedWriter writer,
68              DataExtractorContext ctx) {
69      }
70  
71      public OutgoingBatch extractNodeIdentityFor(Node node, IOutgoingTransport transport) {
72          return null;
73      }
74  
75      public void addExtractorFilter(IExtractorFilter extractorFilter) {
76      }
77  
78      public void extractConfigurationStandalone(Node node, OutputStream out) throws IOException {
79  
80      }
81  
82  }