public void paste() throws ShareException {
	if (filelist == null)
	    throw new ShareException(ShareException.Error.FILELIST_NOT_YET_SET);
	if (pwd == null)
	    pwd = filelist;

	if (cut_buffer == null)
	    throw new ShareException(ShareException.Error.NOTHING_TO_PASTE);
	if (pwd.equals(cut_buffer))
	    throw new ShareException(ShareException.Error.CANNOT_PASTE_DIR_INTO_ITSELF);
	if (pwd.hasChild(cut_buffer))
	    throw new ShareException(ShareException.Error.CANNOT_PASTE_NAME_ALREADY_EXISTS);
	if (cut_buffer instanceof FLDir) {
	    FLDir c = (FLDir) cut_buffer;
	    if (pwd.getDirPath().startsWith(c.getDirPath()))
		throw new ShareException(ShareException.Error.CANNOT_PASTE_NAME_ALREADY_EXISTS);
	}

	if (cut_buffer instanceof FLDir) {
	    FLDir c = (FLDir) cut_buffer;
	    c.getParent().removeSubDir(c);
	    pwd.addSubDir(c);
	    c.setParent(pwd);
	} else {
	    FLFile c = (FLFile) cut_buffer;
	    filelist.deleteFileInTree(c);
	    pwd.addFile(c);
	}
    }