Project

General

Profile

« Previous | Next » 

Revision 1810

Added by Jing Tao over 20 years ago

Fixed some bugs in this file.

View differences:

src/edu/ucsb/nceas/metacat/stringclient/impl/MetacatStringImpl.java
35 35
import java.util.Properties;
36 36

  
37 37
import edu.ucsb.nceas.utilities.HttpMessage;
38
import edu.ucsb.nceas.utilities.IOUtil;
39 38

  
39

  
40 40
import org.globus.ogsa.impl.ogsi.GridServiceImpl;
41 41
import gt3tutorial.core.second.Metacat.MetacatPortType;
42 42
import java.rmi.RemoteException;
......
50 50
                               implements MetacatPortType
51 51
{
52 52
    /** The URL string for the metacat server */
53
    private String metacatUrl;
53
    private String metacatUrl="http://dev.nceas.ucsb.edu/tao/servlet/metacat";
54 54

  
55 55
    /**
56 56
     *  Method used to log in to a metacat server. Implementations will need
......
123 123
        prop.put("qformat", "xml");
124 124
        prop.put("docid", docid);
125 125

  
126
        InputStream response = null;
126
        String response = null;
127 127
        try {
128 128
            response = sendDataForString(prop);
129 129
        } catch (Exception e) {
......
159 159
        
160 160
        String response = null;
161 161
        try {
162
            response = sendDataForString(pop);
162
            response = sendDataForString(prop);
163 163
          
164 164
        } catch (Exception e) {
165 165
            throw new RemoteException(e.getMessage());
......
224 224
        throws RemoteException
225 225
    {
226 226
        String doctext = xmlDocument;
227
        String schematext = Schema;
227
        String schematext = schema;
228 228
      
229 229

  
230 230
        //set up properties
......
286 286

  
287 287
        return response;
288 288
    }
289

  
289
    
290
    /**
291
     * When the MetacatFactory creates an instance it needs to set the
292
     * MetacatUrl to which connections should be made.
293
     *
294
     * @param metacatUrl the URL for the metacat server
295
     */
296
    public void setMetacatUrl(String metacatUrl) throws RemoteException
297
    {
298
      this.metacatUrl = metacatUrl;
299
    }
290 300
 
291 301
    /************************************************************************
292 302
     * PRIVATE METHODS

Also available in: Unified diff