Skip to content
Snippets Groups Projects
Commit e4af92a9 authored by Richard Alam's avatar Richard Alam
Browse files

- start writing record api

parent 63636da8
No related branches found
No related tags found
No related merge requests found
package org.bigbluebutton.api.domain;
import java.io.File;
import java.io.FileFilter;
public class Recordings {
public String[] getRecordings(String recordingDir) {
File dir = new File(recordingDir);
FileFilter fileFilter = new FileFilter() {
public boolean accept(File file) {
return file.isDirectory();
}
};
File[] dirs = dir.listFiles(fileFilter);
String[] meetings = new String[dirs.length];
for (int i = 0; i < dirs.length; i++) {
meetings[i] = dirs[i].getName();
}
return meetings;
}
}
......@@ -21,7 +21,6 @@
package org.bigbluebutton.web.services
import grails.test.*
import org.bigbluebutton.presentation.service.DynamicConference
import org.bigbluebutton.api.domain.DynamicConference
class DynamicConferenceServiceTests extends GrailsUnitTestCase {
......
/* BigBlueButton - http://www.bigbluebutton.org
*
*
* Copyright (c) 2008-2009 by respective authors (see below). All rights reserved.
*
* BigBlueButton is free software; you can redistribute it and/or modify it under the
* terms of the GNU Lesser General Public License as published by the Free Software
* Foundation; either version 3 of the License, or (at your option) any later
* version.
*
* BigBlueButton is distributed in the hope that it will be useful, but WITHOUT ANY
* WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
* PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License along
* with BigBlueButton; if not, If not, see <http://www.gnu.org/licenses/>.
*
* Author: Richard Alam <ritzalam@gmail.com>
* DJP <DJP@architectes.org>
*
* @version $Id: $
*/
package org.bigbluebutton.api.domain;
import java.io.File;
class RecordingsTests extends GroovyTestCase {
def recordings
void setUp() {
println "Test setup"
recordings = new Recordings()
}
void testGetRecordings() {
String[] meetings = recordings.getRecordings("/var/bigbluebutton/recordings")
for (int i = 0; i < meetings.length; i++) {
println meetings[i];
}
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment