1
2
3
4
5
6
7
8
9
10
11 package org.astrogrid.scripting;
12
13 import org.astrogrid.community.User;
14 import org.astrogrid.store.Ivorn;
15 import org.astrogrid.store.VoSpaceClient;
16 import org.astrogrid.store.delegate.StoreClient;
17
18 import java.io.IOException;
19 import java.io.InputStream;
20 import java.io.OutputStream;
21 import java.net.URISyntaxException;
22 import java.net.URL;
23
24 /*** Wrapper of standard vospace client that has string-friendly scripting methods.
25 * @author Noel Winstanley nw@jb.man.ac.uk 30-Nov-2004
26 *
27 */
28 public class ScriptVoSpaceClient extends VoSpaceClient {
29
30 /*** Construct a new ScriptVoSpaceClient
31 * @param arg0
32 */
33 protected ScriptVoSpaceClient(User operator) {
34 super(operator);
35 }
36
37
38 public void copy(String fromIvorn, String toIvorn) throws IOException, URISyntaxException {
39 super.copy(new Ivorn(fromIvorn), new Ivorn(toIvorn));
40 }
41
42 public Ivorn createUser(String arg0, String arg1) throws IOException,
43 URISyntaxException {
44 return super.createUser(new Ivorn(arg0), new Ivorn(arg1));
45 }
46 public void delete(String arg0) throws IOException, URISyntaxException {
47 super.delete(new Ivorn(arg0));
48 }
49 public void deleteUser(String arg0, String arg1) throws IOException, URISyntaxException {
50 super.deleteUser(new Ivorn(arg0), new Ivorn(arg1));
51 }
52 public StoreClient getDelegate(String arg0) throws IOException, URISyntaxException {
53 return super.getDelegate(new Ivorn(arg0));
54 }
55 public InputStream getStream(String arg0) throws IOException, URISyntaxException {
56 return super.getStream(new Ivorn(arg0));
57 }
58 public void move(String arg0, String arg1) throws IOException, URISyntaxException {
59 super.move(new Ivorn(arg0), new Ivorn(arg1));
60 }
61 public void newFolder(String arg0) throws IOException, URISyntaxException {
62 super.newFolder(new Ivorn(arg0));
63 }
64 public void putBytes(byte[] arg0, int arg1, int arg2, String arg3,
65 boolean arg4) throws IOException, URISyntaxException {
66 super.putBytes(arg0, arg1, arg2, new Ivorn(arg3), arg4);
67 }
68 public OutputStream putStream(String arg0) throws IOException, URISyntaxException {
69 return super.putStream(new Ivorn(arg0));
70 }
71 public void putUrl(URL arg0, String arg1, boolean arg2) throws IOException, URISyntaxException {
72 super.putUrl(arg0, new Ivorn(arg1), arg2);
73 }
74
75 public void putUrl(URL arg0, String arg1) throws IOException, URISyntaxException {
76 super.putUrl(arg0, new Ivorn(arg1), false);
77 }
78 }
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95