aboutsummaryrefslogblamecommitdiffstats
path: root/lib/cosFileTransfer/doc/src/CosFileTransfer_FileTransferSession.xml
blob: 19caace060f521a27bfecb40a59410a8a1d2f47c (plain) (tree)
1
2
3
4
5
6
7
8
9
10
                                       




                                     
                                        


                                                        










                                                                              


                  
                                                      








































































































































                                                                                                                                                                                         
                                                                                                                                    







                                                                                 
                                                                                    


















                                                                                                                
<?xml version="1.0" encoding="utf-8" ?>
<!DOCTYPE erlref SYSTEM "erlref.dtd">

<erlref>
  <header>
    <copyright>
      <year>2000</year><year>2013</year>
      <holder>Ericsson AB. All Rights Reserved.</holder>
    </copyright>
    <legalnotice>
      Licensed under the Apache License, Version 2.0 (the "License");
      you may not use this file except in compliance with the License.
      You may obtain a copy of the License at
 
          http://www.apache.org/licenses/LICENSE-2.0

      Unless required by applicable law or agreed to in writing, software
      distributed under the License is distributed on an "AS IS" BASIS,
      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
      See the License for the specific language governing permissions 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>