001 /** 002 * Copyright (c) 2000-2011 Liferay, Inc. All rights reserved. 003 * 004 * This library is free software; you can redistribute it and/or modify it under 005 * the terms of the GNU Lesser General Public License as published by the Free 006 * Software Foundation; either version 2.1 of the License, or (at your option) 007 * any later version. 008 * 009 * This library is distributed in the hope that it will be useful, but WITHOUT 010 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS 011 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more 012 * details. 013 */ 014 015 package com.liferay.portlet.documentlibrary.service.http; 016 017 import com.liferay.portal.kernel.log.Log; 018 import com.liferay.portal.kernel.log.LogFactoryUtil; 019 import com.liferay.portal.kernel.util.ListUtil; 020 021 import com.liferay.portlet.documentlibrary.service.DLAppServiceUtil; 022 023 import java.rmi.RemoteException; 024 025 /** 026 * <p> 027 * This class provides a SOAP utility for the 028 * {@link com.liferay.portlet.documentlibrary.service.DLAppServiceUtil} service utility. The 029 * static methods of this class calls the same methods of the service utility. 030 * However, the signatures are different because it is difficult for SOAP to 031 * support certain types. 032 * </p> 033 * 034 * <p> 035 * The benefits of using the SOAP utility is that it is cross platform 036 * compatible. SOAP allows different languages like Java, .NET, C++, PHP, and 037 * even Perl, to call the generated services. One drawback of SOAP is that it is 038 * slow because it needs to serialize all calls into a text format (XML). 039 * </p> 040 * 041 * <p> 042 * You can see a list of services at 043 * http://localhost:8080/api/secure/axis. Set the property 044 * <b>axis.servlet.hosts.allowed</b> in portal.properties to configure 045 * security. 046 * </p> 047 * 048 * <p> 049 * The SOAP utility is only generated for remote services. 050 * </p> 051 * 052 * @author Brian Wing Shun Chan 053 * @see DLAppServiceHttp 054 * @see com.liferay.portlet.documentlibrary.service.DLAppServiceUtil 055 * @generated 056 */ 057 public class DLAppServiceSoap { 058 /** 059 * Adds a file shortcut to the existing file entry. This method is only 060 * supported by the Liferay repository. 061 * 062 * @param repositoryId the primary key of the repository 063 * @param folderId the primary key of the file shortcut's parent folder 064 * @param toFileEntryId the primary key of the file shortcut's file entry 065 * @param serviceContext the service context to be applied. Can set the 066 asset category IDs, asset tag names, and expando bridge 067 attributes for the file entry. 068 * @return the file shortcut 069 * @throws PortalException if the parent folder or file entry could not be 070 found, or if the file shortcut's information was invalid 071 * @throws SystemException if a system exception occurred 072 */ 073 public static com.liferay.portlet.documentlibrary.model.DLFileShortcutSoap addFileShortcut( 074 long repositoryId, long folderId, long toFileEntryId, 075 com.liferay.portal.service.ServiceContext serviceContext) 076 throws RemoteException { 077 try { 078 com.liferay.portlet.documentlibrary.model.DLFileShortcut returnValue = 079 DLAppServiceUtil.addFileShortcut(repositoryId, folderId, 080 toFileEntryId, serviceContext); 081 082 return com.liferay.portlet.documentlibrary.model.DLFileShortcutSoap.toSoapModel(returnValue); 083 } 084 catch (Exception e) { 085 _log.error(e, e); 086 087 throw new RemoteException(e.getMessage()); 088 } 089 } 090 091 /** 092 * Cancels the check out of the file entry. If a user has not checked out 093 * the specified file entry, invoking this method will result in no changes. 094 * 095 * <p> 096 * When a file entry is checked out, a PWC (private working copy) is created 097 * and the original file entry is locked. A client can make as many changes 098 * to the PWC as he desires without those changes being visible to other 099 * users. If the user is satisfied with the changes, he may elect to check 100 * in his changes, resulting in a new file version based on the PWC; the PWC 101 * will be removed and the file entry will be unlocked. If the user is not 102 * satisfied with the changes, he may elect to cancel his check out; this 103 * results in the deletion of the PWC and unlocking of the file entry. 104 * </p> 105 * 106 * @param fileEntryId the primary key of the file entry to cancel the 107 checkout 108 * @throws PortalException if the file entry could not be found 109 * @throws SystemException if a system exception occurred 110 * @see #checkInFileEntry(long, boolean, String, ServiceContext) 111 * @see #checkOutFileEntry(long) 112 */ 113 public static void cancelCheckOut(long fileEntryId) 114 throws RemoteException { 115 try { 116 DLAppServiceUtil.cancelCheckOut(fileEntryId); 117 } 118 catch (Exception e) { 119 _log.error(e, e); 120 121 throw new RemoteException(e.getMessage()); 122 } 123 } 124 125 /** 126 * Checks in the file entry. If a user has not checked out the specified 127 * file entry, invoking this method will result in no changes. 128 * 129 * <p> 130 * When a file entry is checked out, a PWC (private working copy) is created 131 * and the original file entry is locked. A client can make as many changes 132 * to the PWC as he desires without those changes being visible to other 133 * users. If the user is satisfied with the changes, he may elect to check 134 * in his changes, resulting in a new file version based on the PWC; the PWC 135 * will be removed and the file entry will be unlocked. If the user is not 136 * satisfied with the changes, he may elect to cancel his check out; this 137 * results in the deletion of the PWC and unlocking of the file entry. 138 * </p> 139 * 140 * @param fileEntryId the primary key of the file entry to check in 141 * @param majorVersion whether the new file version is a major version 142 * @param changeLog the file's version change log 143 * @param serviceContext the service context to be applied 144 * @throws PortalException if the file entry could not be found 145 * @throws SystemException if a system exception occurred 146 * @see #cancelCheckOut(long) 147 * @see #checkOutFileEntry(long) 148 */ 149 public static void checkInFileEntry(long fileEntryId, boolean majorVersion, 150 java.lang.String changeLog, 151 com.liferay.portal.service.ServiceContext serviceContext) 152 throws RemoteException { 153 try { 154 DLAppServiceUtil.checkInFileEntry(fileEntryId, majorVersion, 155 changeLog, serviceContext); 156 } 157 catch (Exception e) { 158 _log.error(e, e); 159 160 throw new RemoteException(e.getMessage()); 161 } 162 } 163 164 /** 165 * Checks in the file entry using the lock's UUID. If a user has not checked 166 * out the specified file entry, invoking this method will result in no 167 * changes. This method is primarily used by WebDAV. 168 * 169 * <p> 170 * When a file entry is checked out, a PWC (private working copy) is created 171 * and the original file entry is locked. A client can make as many changes 172 * to the PWC as he desires without those changes being visible to other 173 * users. If the user is satisfied with the changes, he may elect to check 174 * in his changes, resulting in a new file version based on the PWC; the PWC 175 * will be removed and the file entry will be unlocked. If the user is not 176 * satisfied with the changes, he may elect to cancel his check out; this 177 * results in the deletion of the PWC and unlocking of the file entry. 178 * </p> 179 * 180 * @param fileEntryId the primary key of the file entry to check in 181 * @param lockUuid the lock's universally unique identifier 182 * @throws PortalException if the file entry could not be found 183 * @throws SystemException if a system exception occurred 184 * @see #cancelCheckOut(long) 185 * @see #checkOutFileEntry(long, String, long) 186 */ 187 public static void checkInFileEntry(long fileEntryId, 188 java.lang.String lockUuid) throws RemoteException { 189 try { 190 DLAppServiceUtil.checkInFileEntry(fileEntryId, lockUuid); 191 } 192 catch (Exception e) { 193 _log.error(e, e); 194 195 throw new RemoteException(e.getMessage()); 196 } 197 } 198 199 /** 200 * Check out a file entry. 201 * 202 * <p> 203 * When a file entry is checked out, a PWC (private working copy) is created 204 * and the original file entry is locked. A client can make as many changes 205 * to the PWC as he desires without those changes being visible to other 206 * users. If the user is satisfied with the changes, he may elect to check 207 * in his changes, resulting in a new file version based on the PWC; the PWC 208 * will be removed and the file entry will be unlocked. If the user is not 209 * satisfied with the changes, he may elect to cancel his check out; this 210 * results in the deletion of the PWC and unlocking of the file entry. 211 * </p> 212 * 213 * @param fileEntryId the file entry to check out 214 * @throws PortalException if the file entry could not be found 215 * @throws SystemException if a system exception occurred 216 * @see #cancelCheckOut(long) 217 * @see #checkInFileEntry(long, boolean, String, ServiceContext) 218 */ 219 public static void checkOutFileEntry(long fileEntryId) 220 throws RemoteException { 221 try { 222 DLAppServiceUtil.checkOutFileEntry(fileEntryId); 223 } 224 catch (Exception e) { 225 _log.error(e, e); 226 227 throw new RemoteException(e.getMessage()); 228 } 229 } 230 231 /** 232 * Deletes the file entry with the primary key. 233 * 234 * @param fileEntryId the primary key of the file entry 235 * @throws PortalException if the file entry could not be found 236 * @throws SystemException if a system exception occurred 237 */ 238 public static void deleteFileEntry(long fileEntryId) 239 throws RemoteException { 240 try { 241 DLAppServiceUtil.deleteFileEntry(fileEntryId); 242 } 243 catch (Exception e) { 244 _log.error(e, e); 245 246 throw new RemoteException(e.getMessage()); 247 } 248 } 249 250 /** 251 * Deletes the file entry with the title in the folder. 252 * 253 * @param repositoryId the primary key of the repository 254 * @param folderId the primary key of the file entry's parent folder 255 * @param title the file entry's title 256 * @throws PortalException if the file entry could not be found 257 * @throws SystemException if a system exception occurred 258 */ 259 public static void deleteFileEntryByTitle(long repositoryId, long folderId, 260 java.lang.String title) throws RemoteException { 261 try { 262 DLAppServiceUtil.deleteFileEntryByTitle(repositoryId, folderId, 263 title); 264 } 265 catch (Exception e) { 266 _log.error(e, e); 267 268 throw new RemoteException(e.getMessage()); 269 } 270 } 271 272 /** 273 * Deletes the file shortcut with the primary key. This method is only 274 * supported by the Liferay repository. 275 * 276 * @param fileShortcutId the primary key of the file shortcut 277 * @throws PortalException if the file shortcut could not be found 278 * @throws SystemException if a system exception occurred 279 */ 280 public static void deleteFileShortcut(long fileShortcutId) 281 throws RemoteException { 282 try { 283 DLAppServiceUtil.deleteFileShortcut(fileShortcutId); 284 } 285 catch (Exception e) { 286 _log.error(e, e); 287 288 throw new RemoteException(e.getMessage()); 289 } 290 } 291 292 /** 293 * Deletes the folder with the primary key and all of its subfolders and 294 * file entries. 295 * 296 * @param folderId the primary key of the folder 297 * @throws PortalException if the folder could not be found 298 * @throws SystemException if a system exception occurred 299 */ 300 public static void deleteFolder(long folderId) throws RemoteException { 301 try { 302 DLAppServiceUtil.deleteFolder(folderId); 303 } 304 catch (Exception e) { 305 _log.error(e, e); 306 307 throw new RemoteException(e.getMessage()); 308 } 309 } 310 311 /** 312 * Deletes the folder with the name in the parent folder and all of its 313 * subfolders and file entries. 314 * 315 * @param repositoryId the primary key of the repository 316 * @param parentFolderId the primary key of the folder's parent folder 317 * @param name the folder's name 318 * @throws PortalException if the folder could not be found 319 * @throws SystemException if a system exception occurred 320 */ 321 public static void deleteFolder(long repositoryId, long parentFolderId, 322 java.lang.String name) throws RemoteException { 323 try { 324 DLAppServiceUtil.deleteFolder(repositoryId, parentFolderId, name); 325 } 326 catch (Exception e) { 327 _log.error(e, e); 328 329 throw new RemoteException(e.getMessage()); 330 } 331 } 332 333 /** 334 * Deletes the temporary file entry. 335 * 336 * @param groupId the primary key of the group 337 * @param folderId the primary key of the folder where the file entry was 338 eventually to reside 339 * @param fileName the file's original name 340 * @param tempFolderName the temporary folder's name 341 * @throws PortalException if the file name was invalid 342 * @throws SystemException if a system exception occurred 343 * @see com.liferay.portal.kernel.util.TempFileUtil 344 */ 345 public static void deleteTempFileEntry(long groupId, long folderId, 346 java.lang.String fileName, java.lang.String tempFolderName) 347 throws RemoteException { 348 try { 349 DLAppServiceUtil.deleteTempFileEntry(groupId, folderId, fileName, 350 tempFolderName); 351 } 352 catch (Exception e) { 353 _log.error(e, e); 354 355 throw new RemoteException(e.getMessage()); 356 } 357 } 358 359 /** 360 * Returns the number of file entries and shortcuts in the folder. 361 * 362 * @param repositoryId the primary key of the repository 363 * @param folderId the primary key of the folder 364 * @param status the workflow status 365 * @return the number of file entries and shortcuts in the folder 366 * @throws PortalException if the folder ould not be found 367 * @throws SystemException if a system exception occurred 368 */ 369 public static int getFileEntriesAndFileShortcutsCount(long repositoryId, 370 long folderId, int status) throws RemoteException { 371 try { 372 int returnValue = DLAppServiceUtil.getFileEntriesAndFileShortcutsCount(repositoryId, 373 folderId, status); 374 375 return returnValue; 376 } 377 catch (Exception e) { 378 _log.error(e, e); 379 380 throw new RemoteException(e.getMessage()); 381 } 382 } 383 384 /** 385 * Returns the number of file entries in the folder. 386 * 387 * @param repositoryId the primary key of the file entry's repository 388 * @param folderId the primary key of the file entry's folder 389 * @return the number of file entries in the folder 390 * @throws PortalException if the folder could not be found 391 * @throws SystemException if a system exception occurred 392 */ 393 public static int getFileEntriesCount(long repositoryId, long folderId) 394 throws RemoteException { 395 try { 396 int returnValue = DLAppServiceUtil.getFileEntriesCount(repositoryId, 397 folderId); 398 399 return returnValue; 400 } 401 catch (Exception e) { 402 _log.error(e, e); 403 404 throw new RemoteException(e.getMessage()); 405 } 406 } 407 408 /** 409 * Returns the number of file entries with the file entry type in the 410 * folder. 411 * 412 * @param repositoryId the primary key of the file entry's repository 413 * @param folderId the primary key of the file entry's folder 414 * @param fileEntryTypeId the primary key of the file entry type 415 * @return the number of file entries with the file entry type in the folder 416 * @throws PortalException if the folder could not be found 417 * @throws SystemException if a system exception occurred 418 */ 419 public static int getFileEntriesCount(long repositoryId, long folderId, 420 long fileEntryTypeId) throws RemoteException { 421 try { 422 int returnValue = DLAppServiceUtil.getFileEntriesCount(repositoryId, 423 folderId, fileEntryTypeId); 424 425 return returnValue; 426 } 427 catch (Exception e) { 428 _log.error(e, e); 429 430 throw new RemoteException(e.getMessage()); 431 } 432 } 433 434 /** 435 * Returns the file shortcut with the primary key. This method is only 436 * supported by the Liferay repository. 437 * 438 * @param fileShortcutId the primary key of the file shortcut 439 * @return the file shortcut with the primary key 440 * @throws PortalException if the file shortcut could not be found 441 * @throws SystemException if a system exception occurred 442 */ 443 public static com.liferay.portlet.documentlibrary.model.DLFileShortcutSoap getFileShortcut( 444 long fileShortcutId) throws RemoteException { 445 try { 446 com.liferay.portlet.documentlibrary.model.DLFileShortcut returnValue = 447 DLAppServiceUtil.getFileShortcut(fileShortcutId); 448 449 return com.liferay.portlet.documentlibrary.model.DLFileShortcutSoap.toSoapModel(returnValue); 450 } 451 catch (Exception e) { 452 _log.error(e, e); 453 454 throw new RemoteException(e.getMessage()); 455 } 456 } 457 458 /** 459 * Returns the number of immediate subfolders, file entries, and file 460 * shortcuts in the parent folder. 461 * 462 * @param repositoryId the primary key of the repository 463 * @param folderId the primary key of the parent folder 464 * @param status the workflow status 465 * @param includeMountFolders whether to include mount folders for 466 third-party repositories 467 * @return the number of immediate subfolders, file entries, and file 468 shortcuts in the parent folder 469 * @throws PortalException if the folder could not be found 470 * @throws SystemException if a system exception occurred 471 */ 472 public static int getFoldersAndFileEntriesAndFileShortcutsCount( 473 long repositoryId, long folderId, int status, 474 boolean includeMountFolders) throws RemoteException { 475 try { 476 int returnValue = DLAppServiceUtil.getFoldersAndFileEntriesAndFileShortcutsCount(repositoryId, 477 folderId, status, includeMountFolders); 478 479 return returnValue; 480 } 481 catch (Exception e) { 482 _log.error(e, e); 483 484 throw new RemoteException(e.getMessage()); 485 } 486 } 487 488 public static int getFoldersAndFileEntriesAndFileShortcutsCount( 489 long repositoryId, long folderId, int status, 490 java.lang.String[] mimeTypes, boolean includeMountFolders) 491 throws RemoteException { 492 try { 493 int returnValue = DLAppServiceUtil.getFoldersAndFileEntriesAndFileShortcutsCount(repositoryId, 494 folderId, status, mimeTypes, includeMountFolders); 495 496 return returnValue; 497 } 498 catch (Exception e) { 499 _log.error(e, e); 500 501 throw new RemoteException(e.getMessage()); 502 } 503 } 504 505 /** 506 * Returns the number of immediate subfolders of the parent folder. 507 * 508 * @param repositoryId the primary key of the folder's repository 509 * @param parentFolderId the primary key of the folder's parent folder 510 * @return the number of immediate subfolders of the parent folder 511 * @throws PortalException if the parent folder could not be found 512 * @throws SystemException if a system exception occurred 513 */ 514 public static int getFoldersCount(long repositoryId, long parentFolderId) 515 throws RemoteException { 516 try { 517 int returnValue = DLAppServiceUtil.getFoldersCount(repositoryId, 518 parentFolderId); 519 520 return returnValue; 521 } 522 catch (Exception e) { 523 _log.error(e, e); 524 525 throw new RemoteException(e.getMessage()); 526 } 527 } 528 529 /** 530 * Returns the number of immediate subfolders of the parent folder, 531 * optionally including mount folders for third-party repositories. 532 * 533 * @param repositoryId the primary key of the folder's repository 534 * @param parentFolderId the primary key of the folder's parent folder 535 * @param includeMountFolders whether to include mount folders for 536 third-party repositories 537 * @return the number of immediate subfolders of the parent folder 538 * @throws PortalException if the parent folder could not be found 539 * @throws SystemException if a system exception occurred 540 */ 541 public static int getFoldersCount(long repositoryId, long parentFolderId, 542 boolean includeMountFolders) throws RemoteException { 543 try { 544 int returnValue = DLAppServiceUtil.getFoldersCount(repositoryId, 545 parentFolderId, includeMountFolders); 546 547 return returnValue; 548 } 549 catch (Exception e) { 550 _log.error(e, e); 551 552 throw new RemoteException(e.getMessage()); 553 } 554 } 555 556 /** 557 * Returns the number of immediate subfolders and file entries across the 558 * folders. 559 * 560 * @param repositoryId the primary key of the repository 561 * @param folderIds the primary keys of folders from which to count 562 immediate subfolders and file entries 563 * @param status the workflow status 564 * @return the number of immediate subfolders and file entries across the 565 folders 566 * @throws PortalException if the repository could not be found 567 * @throws SystemException if a system exception occurred 568 */ 569 public static int getFoldersFileEntriesCount(long repositoryId, 570 Long[] folderIds, int status) throws RemoteException { 571 try { 572 int returnValue = DLAppServiceUtil.getFoldersFileEntriesCount(repositoryId, 573 ListUtil.toList(folderIds), status); 574 575 return returnValue; 576 } 577 catch (Exception e) { 578 _log.error(e, e); 579 580 throw new RemoteException(e.getMessage()); 581 } 582 } 583 584 /** 585 * Returns the number of file entries in a group starting at the repository 586 * default parent folder that are stored within the Liferay repository. This 587 * method is primarily used to search for recently modified file entries. It 588 * can be limited to the file entries modified by a given user. 589 * 590 * @param groupId the primary key of the group 591 * @param userId the primary key of the user who created the file 592 (optionally <code>0</code>) 593 * @return the number of matching file entries 594 * @throws PortalException if the group could not be found 595 * @throws SystemException if a system exception occurred 596 */ 597 public static int getGroupFileEntriesCount(long groupId, long userId) 598 throws RemoteException { 599 try { 600 int returnValue = DLAppServiceUtil.getGroupFileEntriesCount(groupId, 601 userId); 602 603 return returnValue; 604 } 605 catch (Exception e) { 606 _log.error(e, e); 607 608 throw new RemoteException(e.getMessage()); 609 } 610 } 611 612 /** 613 * Returns the number of file entries in a group starting at the root folder 614 * that are stored within the Liferay repository. This method is primarily 615 * used to search for recently modified file entries. It can be limited to 616 * the file entries modified by a given user. 617 * 618 * @param groupId the primary key of the group 619 * @param userId the primary key of the user who created the file 620 (optionally <code>0</code>) 621 * @param rootFolderId the primary key of the root folder to begin the 622 search 623 * @return the number of matching file entries 624 * @throws PortalException if the group could not be found 625 * @throws SystemException if a system exception occurred 626 */ 627 public static int getGroupFileEntriesCount(long groupId, long userId, 628 long rootFolderId) throws RemoteException { 629 try { 630 int returnValue = DLAppServiceUtil.getGroupFileEntriesCount(groupId, 631 userId, rootFolderId); 632 633 return returnValue; 634 } 635 catch (Exception e) { 636 _log.error(e, e); 637 638 throw new RemoteException(e.getMessage()); 639 } 640 } 641 642 public static void getSubfolderIds(long repositoryId, Long[] folderIds, 643 long folderId) throws RemoteException { 644 try { 645 DLAppServiceUtil.getSubfolderIds(repositoryId, 646 ListUtil.toList(folderIds), folderId); 647 } 648 catch (Exception e) { 649 _log.error(e, e); 650 651 throw new RemoteException(e.getMessage()); 652 } 653 } 654 655 /** 656 * Returns all the descendant folders of the folder with the primary key. 657 * 658 * @param repositoryId the primary key of the repository 659 * @param folderId the primary key of the folder 660 * @return the descendant folders of the folder with the primary key 661 * @throws PortalException if the repository or parent folder could not be 662 found 663 * @throws SystemException if a system exception occurred 664 */ 665 public static java.lang.Long[] getSubfolderIds(long repositoryId, 666 long folderId) throws RemoteException { 667 try { 668 java.util.List<java.lang.Long> returnValue = DLAppServiceUtil.getSubfolderIds(repositoryId, 669 folderId); 670 671 return returnValue.toArray(new java.lang.Long[returnValue.size()]); 672 } 673 catch (Exception e) { 674 _log.error(e, e); 675 676 throw new RemoteException(e.getMessage()); 677 } 678 } 679 680 /** 681 * Returns descendant folders of the folder with the primary key, optionally 682 * limiting to one level deep. 683 * 684 * @param repositoryId the primary key of the repository 685 * @param folderId the primary key of the folder 686 * @param recurse whether to recurse through each subfolder 687 * @return the descendant folders of the folder with the primary key 688 * @throws PortalException if the repository or parent folder could not be 689 found 690 * @throws SystemException if a system exception occurred 691 */ 692 public static java.lang.Long[] getSubfolderIds(long repositoryId, 693 long folderId, boolean recurse) throws RemoteException { 694 try { 695 java.util.List<java.lang.Long> returnValue = DLAppServiceUtil.getSubfolderIds(repositoryId, 696 folderId, recurse); 697 698 return returnValue.toArray(new java.lang.Long[returnValue.size()]); 699 } 700 catch (Exception e) { 701 _log.error(e, e); 702 703 throw new RemoteException(e.getMessage()); 704 } 705 } 706 707 /** 708 * Returns all the temporary file entry names. 709 * 710 * @param groupId the primary key of the group 711 * @param folderId the primary key of the folder where the file entry will 712 eventually reside 713 * @param tempFolderName the temporary folder's name 714 * @return the temporary file entry names 715 * @throws PortalException if the folder was invalid 716 * @throws SystemException if a system exception occurred 717 * @see #addTempFileEntry(long, long, String, String, File) 718 * @see com.liferay.portal.kernel.util.TempFileUtil 719 */ 720 public static java.lang.String[] getTempFileEntryNames(long groupId, 721 long folderId, java.lang.String tempFolderName) 722 throws RemoteException { 723 try { 724 java.lang.String[] returnValue = DLAppServiceUtil.getTempFileEntryNames(groupId, 725 folderId, tempFolderName); 726 727 return returnValue; 728 } 729 catch (Exception e) { 730 _log.error(e, e); 731 732 throw new RemoteException(e.getMessage()); 733 } 734 } 735 736 /** 737 * Reverts the file entry to a previous version. A new version will be 738 * created based on the previous version and metadata. 739 * 740 * @param fileEntryId the primary key of the file entry 741 * @param version the version to revert back to 742 * @param serviceContext the service context to be applied 743 * @throws PortalException if the file entry or version could not be found 744 * @throws SystemException if a system exception occurred 745 */ 746 public static void revertFileEntry(long fileEntryId, 747 java.lang.String version, 748 com.liferay.portal.service.ServiceContext serviceContext) 749 throws RemoteException { 750 try { 751 DLAppServiceUtil.revertFileEntry(fileEntryId, version, 752 serviceContext); 753 } 754 catch (Exception e) { 755 _log.error(e, e); 756 757 throw new RemoteException(e.getMessage()); 758 } 759 } 760 761 /** 762 * Unlocks the folder. This method is primarily used by WebDAV. 763 * 764 * @param repositoryId the primary key of the repository 765 * @param folderId the primary key of the folder 766 * @param lockUuid the lock's universally unique identifier 767 * @throws PortalException if the repository or folder could not be found 768 * @throws SystemException if a system exception occurred 769 */ 770 public static void unlockFolder(long repositoryId, long folderId, 771 java.lang.String lockUuid) throws RemoteException { 772 try { 773 DLAppServiceUtil.unlockFolder(repositoryId, folderId, lockUuid); 774 } 775 catch (Exception e) { 776 _log.error(e, e); 777 778 throw new RemoteException(e.getMessage()); 779 } 780 } 781 782 /** 783 * Unlocks the folder. This method is primarily used by WebDAV. 784 * 785 * @param repositoryId the primary key of the repository 786 * @param parentFolderId the primary key of the parent folder 787 * @param name the folder's name 788 * @param lockUuid the lock's universally unique identifier 789 * @throws PortalException if the repository or folder could not be found 790 * @throws SystemException if a system exception occurred 791 */ 792 public static void unlockFolder(long repositoryId, long parentFolderId, 793 java.lang.String name, java.lang.String lockUuid) 794 throws RemoteException { 795 try { 796 DLAppServiceUtil.unlockFolder(repositoryId, parentFolderId, name, 797 lockUuid); 798 } 799 catch (Exception e) { 800 _log.error(e, e); 801 802 throw new RemoteException(e.getMessage()); 803 } 804 } 805 806 /** 807 * Updates a file shortcut to the existing file entry. This method is only 808 * supported by the Liferay repository. 809 * 810 * @param fileShortcutId the primary key of the file shortcut 811 * @param folderId the primary key of the file shortcut's parent folder 812 * @param toFileEntryId the primary key of the file shortcut's file entry 813 * @param serviceContext the service context to be applied. Can set the 814 asset category IDs, asset tag names, and expando bridge 815 attributes for the file entry. 816 * @return the file shortcut 817 * @throws PortalException if the file shortcut, folder, or file entry could 818 not be found 819 * @throws SystemException if a system exception occurred 820 */ 821 public static com.liferay.portlet.documentlibrary.model.DLFileShortcutSoap updateFileShortcut( 822 long fileShortcutId, long folderId, long toFileEntryId, 823 com.liferay.portal.service.ServiceContext serviceContext) 824 throws RemoteException { 825 try { 826 com.liferay.portlet.documentlibrary.model.DLFileShortcut returnValue = 827 DLAppServiceUtil.updateFileShortcut(fileShortcutId, folderId, 828 toFileEntryId, serviceContext); 829 830 return com.liferay.portlet.documentlibrary.model.DLFileShortcutSoap.toSoapModel(returnValue); 831 } 832 catch (Exception e) { 833 _log.error(e, e); 834 835 throw new RemoteException(e.getMessage()); 836 } 837 } 838 839 /** 840 * Returns <code>true</code> if the file entry is checked out. This method 841 * is primarily used by WebDAV. 842 * 843 * @param repositoryId the primary key for the repository 844 * @param fileEntryId the primary key for the file entry 845 * @param lockUuid the lock's universally unique identifier 846 * @return <code>true</code> if the file entry is checked out; 847 <code>false</code> otherwise 848 * @throws PortalException if the file entry could not be found 849 * @throws SystemException if a system exception occurred 850 */ 851 public static boolean verifyFileEntryCheckOut(long repositoryId, 852 long fileEntryId, java.lang.String lockUuid) throws RemoteException { 853 try { 854 boolean returnValue = DLAppServiceUtil.verifyFileEntryCheckOut(repositoryId, 855 fileEntryId, lockUuid); 856 857 return returnValue; 858 } 859 catch (Exception e) { 860 _log.error(e, e); 861 862 throw new RemoteException(e.getMessage()); 863 } 864 } 865 866 /** 867 * Returns <code>true</code> if the inheritable lock exists. This method is 868 * primarily used by WebDAV. 869 * 870 * @param repositoryId the primary key for the repository 871 * @param folderId the primary key for the folder 872 * @param lockUuid the lock's universally unique identifier 873 * @return <code>true</code> if the inheritable lock exists; 874 <code>false</code> otherwise 875 * @throws PortalException if the folder could not be found 876 * @throws SystemException if a system exception occurred 877 */ 878 public static boolean verifyInheritableLock(long repositoryId, 879 long folderId, java.lang.String lockUuid) throws RemoteException { 880 try { 881 boolean returnValue = DLAppServiceUtil.verifyInheritableLock(repositoryId, 882 folderId, lockUuid); 883 884 return returnValue; 885 } 886 catch (Exception e) { 887 _log.error(e, e); 888 889 throw new RemoteException(e.getMessage()); 890 } 891 } 892 893 private static Log _log = LogFactoryUtil.getLog(DLAppServiceSoap.class); 894 }