Revision: 3946
Author:   seba.wagner
Date:     Sun Jul  3 08:28:03 2011
Log:      Add New Method Call to SOAP/REST API
http://code.google.com/p/openmeetings/source/detail?r=3946

Modified:
 /trunk/singlewebapp/build.xml
/trunk/singlewebapp/src/fileservice/org/openmeetings/axis/services/FileService.java

=======================================
--- /trunk/singlewebapp/build.xml       Sun Jul  3 05:15:21 2011
+++ /trunk/singlewebapp/build.xml       Sun Jul  3 08:28:03 2011
@@ -452,6 +452,10 @@
                 <include name="META-INF/**"/>
             </fileset>
             <fileset dir="${classes.dir}">
+ <include name="org/openmeetings/app/data/file/dto/LibraryPresentation.class"/> + <include name="org/openmeetings/app/data/file/dto/LibraryPresenationThumbs.class"/> + <include name="org/openmeetings/app/data/file/dto/LibraryPresentationFile.class"/> + <include name="org/openmeetings/app/data/file/dto/LibraryPresentationThumb.class"/> <include name="org/openmeetings/axis/services/FileService.class"/> <include name="org/openmeetings/axis/services/FileImportError.class"/>
             </fileset>
=======================================
--- /trunk/singlewebapp/src/fileservice/org/openmeetings/axis/services/FileService.java Fri Jul 1 00:47:55 2011 +++ /trunk/singlewebapp/src/fileservice/org/openmeetings/axis/services/FileService.java Sun Jul 3 08:28:03 2011
@@ -1,6 +1,7 @@
 package org.openmeetings.axis.services;

 import java.io.BufferedInputStream;
+import java.io.File;
 import java.io.InputStream;
 import java.net.URL;
 import java.net.URLConnection;
@@ -23,8 +24,10 @@
 import org.openmeetings.app.data.basic.files.*;
 import org.openmeetings.app.data.file.FileProcessor;
 import org.openmeetings.app.data.file.dao.FileExplorerItemDaoImpl;
+import org.openmeetings.app.data.file.dto.LibraryPresentation;
 import org.openmeetings.app.data.user.Usermanagement;
 import org.openmeetings.app.data.user.dao.UsersDaoImpl;
+import org.openmeetings.app.documents.LoadLibraryPresentation;
 import org.openmeetings.app.hibernate.beans.user.Users;
 import org.openmeetings.app.remote.ConferenceLibrary;
 import org.openmeetings.app.remote.red5.ScopeApplicationAdapter;
@@ -363,7 +366,7 @@
         * @param externalType
         * @return
         */
- public Long deleteFileOrFolderByExternalIdAndType(String SID, Long externalFilesid, String externalType){ + public Long deleteFileOrFolderByExternalIdAndType(String SID, Long externalFilesid, String externalType) throws AxisFault {

                try {

@@ -391,7 +394,7 @@
         * @param fileExplorerItemId
         * @return
         */
-       public Long deleteFileOrFolder(String SID, Long fileExplorerItemId){
+ public Long deleteFileOrFolder(String SID, Long fileExplorerItemId) throws AxisFault {

                try {

@@ -421,6 +424,46 @@
                }
                return null;
        }
+
+       public LibraryPresentation getPresentationPreviewFileExplorer(String 
SID,
+                       String parentFolder) throws AxisFault {
+
+           try {
+
+               Long users_id = 
Sessionmanagement.getInstance().checkSession(SID);
+               Long user_level = Usermanagement.getInstance().getUserLevelByID(
+                       users_id);
+
+ if (AuthLevelmanagement.getInstance().checkWebServiceLevel(user_level)) {
+
+                   String current_dir = ScopeApplicationAdapter.webAppPath
+                           + File.separatorChar + "upload";
+ String working_dir = current_dir + File.separatorChar + "files"
+                               + File.separatorChar+ parentFolder;
+                   log.debug("############# working_dir : " + working_dir);
+
+ File file = new File(working_dir + File.separatorChar + "library.xml");
+
+                   if (!file.exists()) {
+ throw new Exception("library.xml does not exist "+working_dir + File.separatorChar + "library.xml");
+                   }
+
+                   return LoadLibraryPresentation.getInstance()
+                                           .parseLibraryFileToObject(
+                                                   file.getAbsolutePath());
+
+               } else {
+
+                   throw new Exception("not Authenticated");
+
+               }
+
+           } catch (Exception e) {
+               log.error("[getListOfFilesByAbsolutePath]", e);
+               return null;
+           }
+
+       }


        /**

--
You received this message because you are subscribed to the Google Groups 
"OpenMeetings developers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/openmeetings-dev?hl=en.

Reply via email to