src/java/fr/jayasoft/ivy/repository/vfs/VfsRepository.java
/**
	 * Transfer an Ivy resource to a VFS repository
	 * 
	 * @param source a <code>File</code> indentifying the local file to transfer to the repository
	 * @param vfsURI a <code>String</code> identifying the destination VFS Resource.
	 * @param overwrite whether to overwrite an existing resource.
	 * @throws <code>IOException</code> on failure.
	 * @see "Supported File Systems in the jakarta-commons-vfs documentation"
	 * 
	 */
Transfer an Ivy resource to a VFS repository

@param source a File indentifying the local file to transfer to the repository
@param vfsURI a String identifying the destination VFS Resource.
@param overwrite whether to overwrite an existing resource.
@throws IOException on failure.
@see "Supported File Systems in the jakarta-commons-vfs documentation"
Transfer an Ivy resource to a VFS repository @param source a File indentifying the local file to transfer to the repository @param vfsURI a String identifying the destination VFS Resource . @param overwrite whether to overwrite an existing resource . @throws IOException on failure . @see " Supported File Systems in the jakarta - commons - vfs documentation "
public void put(File source, String vfsURI, boolean overwrite) throws IOException {
		VfsResource dest = new VfsResource(vfsURI, getVFSManager());
		fireTransferInitiated(dest, TransferEvent.REQUEST_PUT);
		if (dest.physicallyExists() && ! overwrite) {
			throw new IOException("Cannot copy. Destination file: " + dest.getName() + " exists and overwrite not set.");
		}
        if (dest.getContent() == null) {
            throw new IllegalArgumentException("invalid vfs uri "+vfsURI+" to put data to: resource has no content");
        }
		FileUtil.copy(new FileInputStream(source),
				       dest.getContent().getOutputStream(),
				       _progress);
	}
public void put ( File source , String vfsURI , boolean overwrite ) throws IOException { VfsResource dest = new VfsResource ( vfsURI , getVFSManager ( ) ) ; fireTransferInitiated ( dest , TransferEvent . REQUEST_PUT ) ; if ( dest . physicallyExists ( ) && ! overwrite ) { throw new IOException ( "Cannot copy. Destination file: " + dest . getName ( ) + " exists and overwrite not set." ) ; } if ( dest . getContent ( ) == null ) { throw new IllegalArgumentException ( "invalid vfs uri " + vfsURI + " to put data to: resource has no content" ) ; } FileUtil . copy ( new FileInputStream ( source ) , dest . getContent ( ) . getOutputStream ( ) , _progress ) ; }
Transfer an Ivy resource to a VFS repository
Transfer an Ivy resource to a VFS repository