aboutsummaryrefslogtreecommitdiffstats
path: root/lib/cosFileTransfer/doc/src/CosFileTransfer_FileTransferSession.xml
blob: 918f0bf9f72046ea74aac70bb7cfb14c9293c2ff (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
<?xml version="1.0" encoding="latin1" ?>
<!DOCTYPE erlref SYSTEM "erlref.dtd">

<erlref>
  <header>
    <copyright>
      <year>2000</year><year>2011</year>
      <holder>Ericsson AB. All Rights Reserved.</holder>
    </copyright>
    <legalnotice>
      The contents of this file are subject to the Erlang Public License,
      Version 1.1, (the "License"); you may not use this file except in
      compliance with the License. You should have received a copy of the
      Erlang Public License along with this software. If not, it can be
      retrieved online at http://www.erlang.org/.
    
      Software distributed under the License is distributed on an "AS IS"
      basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
      the License for the specific language governing rights and limitations
      under the License.
    
    </legalnotice>

    <title>CosFileTransfer_FileTransferSession</title>
    <prepared></prepared>
    <docno></docno>
    <checked></checked>
    <date>2000-11-09</date>
    <rev>PA1</rev>
  </header>
  <module>CosFileTransfer_FileTransferSession</module>
  <modulesummary>This module implements the OMG CosFileTransfer::FileTransferSession interface.</modulesummary>
  <description>
    <p>To get access to the record definitions for the structures use:      <br></br>
<c>-include_lib("cosFileTransfer/include/*.hrl").</c></p>
  </description>
  <funcs>
    <func>
      <name>'_get_protocols_supported'(FTS) -> Return</name>
      <fsummary>Return the protocols supported by the target object</fsummary>
      <type>
        <v>FTS = #objref</v>
        <v>Return = [#'CosFileTransfer_ProtocolSupport'{protocol_name=Type, addresses=[Address]}]</v>
        <v>Type = Address = string()</v>
      </type>
      <desc>
        <p>This read only attribute returns the protocols supported by the
          target object.</p>
      </desc>
    </func>
    <func>
      <name>set_directory(FTS, Directory) -> Return</name>
      <fsummary>Change the current working directory of the target object's associated file system</fsummary>
      <type>
        <v>FTS = Directory = #objref</v>
        <v>Return = ok | {'EXCEPTION, E}</v>
      </type>
      <desc>
        <p>Invoking this operation will change the current working directory of
          the target object's associated file system. If fail to do so the
          appropriate exception is raised. </p>
      </desc>
    </func>
    <func>
      <name>create_file(FTS, FileNameList) -> Return</name>
      <fsummary>Create a <c>File</c>Object representing a file which  may or may not exist</fsummary>
      <type>
        <v>FTS = #objref</v>
        <v>FileNameList = [string()]</v>
        <v>Return = File | {'EXCEPTION, E}</v>
        <v>File = #objref</v>
      </type>
      <desc>
        <p>This operation creates a <c>File</c> Object representing a file which 
          may or may not exist. 
          For this operation to be independent of the working directory the
          supplied <c>FileNameList</c> must represent the absolute name.</p>
      </desc>
    </func>
    <func>
      <name>create_directory(FTS, FileNameList) -> Return</name>
      <fsummary>Create a new directory in the target objects associated file systems domain</fsummary>
      <type>
        <v>FTS = #objref</v>
        <v>FileNameList = [string()]</v>
        <v>Return = Directory | {'EXCEPTION, E}</v>
        <v>Directory = #objref</v>
      </type>
      <desc>
        <p>This operation creates a new directory in the target objects associated
          file systems domain. If fail to do so an exception is raised but,
          if successful, a <c>Directory</c> object representing the new
          directory is returned.</p>
      </desc>
    </func>
    <func>
      <name>get_file(FTS, FileNameList) -> Return</name>
      <fsummary>Create a <c>FileWrapper</c>which represents a file or directory</fsummary>
      <type>
        <v>FTS = #objref</v>
        <v>FileNameList = [string()]</v>
        <v>Return = FileWrapper | {'EXCEPTION, E}</v>
        <v>FileWrapper = #'CosFileTransfer_FileWrapper'{the_file = File file_type = Type}</v>
        <v>File = #objref</v>
        <v>Type = nfile | ndirectory</v>
      </type>
      <desc>
        <p>This operation, creates a <c>FileWrapper</c> which represents a file or directory, and 
          should be independent of the working Directory,
          i.e., a full path name must be supplied. Furthermore, the file or
          directory represented by the <c>FileNameList</c> must exist.</p>
      </desc>
    </func>
    <func>
      <name>delete(FTS, File) -> Return</name>
      <fsummary>Delete the file or directory, represented by the <c>File</c>object, from the target objects associated file system</fsummary>
      <type>
        <v>FTS = File = #objref</v>
        <v>Return = ok | {'EXCEPTION', E}</v>
      </type>
      <desc>
        <p>This operation removes the file or directory, represented by the <c>File</c>
          object, from the target objects associated file system. If it is a non-empty
          directory or non-existing file or directory an exception is raised.</p>
      </desc>
    </func>
    <func>
      <name>transfer(FTS, SourceFile, DestinationFile) -> Return</name>
      <fsummary>Copy the file represented by the <c>SourceFile</c>from the target  object's file system to a file in the destination <c>FileTransferSession's</c>file system</fsummary>
      <type>
        <v>FTS = SourceFile = DestinationFile = #objref</v>
        <v>Return = ok | {'EXCEPTION', E}</v>
      </type>
      <desc>
        <p>If the target object's and the <c>DestinationFile's</c> associated
          <c>FileTransferSession's</c> support the same protocol(s) this operation
          will copy the file represented by the <c>SourceFile</c> from the target 
          object's file system to a file in the destination 
          <c>FileTransferSession's</c> file system. The file is represented by the
          <c>DestinationFile</c> object and may not exist.
          This operation must be invoked on the <c>FileTransferSession</c>
          associated with the <c>SourceFile</c> object.</p>
      </desc>
    </func>
    <func>
      <name>append(FTS, SourceFile, DestinationFile) -> Return</name>
      <fsummary>Append the file represented by the <c>SourceFile</c>from the target  object's file system to a file in the destination <c>FileTransferSession's</c>file system</fsummary>
      <type>
        <v>FTS = SourceFile = DestinationFile = #objref</v>
        <v>Return =  ok | {'EXCEPTION', E}</v>
      </type>
      <desc>
        <p>This operation behaves almost like the <c>transfer/3</c> operation. The
          difference is that the <c>DestinationFile</c> must exist since the
          <c>SourceFile</c> will be appended to the <c>DestinationFile</c>.</p>
        <p>Currently, it is not possible to use this operation when the target 
          object represents FTP.</p>
      </desc>
    </func>
    <func>
      <name>insert(FTS, SourceFile, DestinationFile, Offset) -> Return</name>
      <fsummary>Insert the <c>SourceFile</c>into the <c>DestinationFile</c> <c>Offset</c>bytes from the start of the file</fsummary>
      <type>
        <v>FTS = SourceFile = DestinationFile = #objref</v>
        <v>Offset = long()</v>
        <v>Return =  ok | {'EXCEPTION', E}</v>
      </type>
      <desc>
        <p>This operation behaves almost like the <c>append/3</c> operation. The 
          difference is that the <c>SourceFile</c> will be inserted into the
          <c>DestinationFile</c> <c>Offset</c> bytes from the start of the file.</p>
        <p>Currently, it is not possible to use this operation when the target 
          object represents FTP.</p>
      </desc>
    </func>
    <func>
      <name>logout(FTS) -> ok</name>
      <fsummary>Terminate the target object and close the connection to the file system it represents</fsummary>
      <type>
        <v>FTS = #objref</v>
      </type>
      <desc>
        <p>This operation terminates the target object and closes the connection
          to the file system it represents.</p>
      </desc>
    </func>
  </funcs>
  
</erlref>