ch.busyboxes.agoo.service.impl
Class WatchedFolderServiceImpl

java.lang.Object
  extended by ch.busyboxes.agoo.service.impl.WatchedFolderServiceImpl
All Implemented Interfaces:
WatchedFolderService

public class WatchedFolderServiceImpl
extends java.lang.Object
implements WatchedFolderService

Implementation of the watched folder service

Author:
julien@busyboxes.ch

Constructor Summary
WatchedFolderServiceImpl()
           
 
Method Summary
 WebWatchedFolder createWatchedFolderByPath(java.lang.String folderPath)
          Creates a new watched folder with the given path
 void deleteWatchedFolder(java.lang.Long folderId)
          Deletes the given watched folder
 java.util.List<WebWatchedFolder> getAllWatchedFolders()
          Returns the list of all watched folders
 WebWatchedFolder getWatchedFolderById(java.lang.Long folderId)
          Gets a watched folder by ID
 void refreshWatchedFilesInWatchedFolder(java.lang.Long folderId)
          Refreshes the files present in the given folder
 void setFileSystemDAO(FileSystemDAO fileSystemDAO)
          The file system DAO used in this service
 void setWatchedFolderDAO(WatchedFolderDAO watchedFolderDAO)
          The watched folders DAO used in this service
 void setWatcherTaskService(WatcherTaskService watcherTaskService)
          The service used to create new task
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WatchedFolderServiceImpl

public WatchedFolderServiceImpl()
Method Detail

getAllWatchedFolders

public java.util.List<WebWatchedFolder> getAllWatchedFolders()
Description copied from interface: WatchedFolderService
Returns the list of all watched folders

Specified by:
getAllWatchedFolders in interface WatchedFolderService
Returns:
the list of all watched folders
See Also:
WatchedFolderService.getAllWatchedFolders()

createWatchedFolderByPath

public WebWatchedFolder createWatchedFolderByPath(java.lang.String folderPath)
Description copied from interface: WatchedFolderService
Creates a new watched folder with the given path

Specified by:
createWatchedFolderByPath in interface WatchedFolderService
Parameters:
folderPath - a folder's path
Returns:
the created watched folder
See Also:
WatchedFolderService.createWatchedFolderByPath(String)

setWatchedFolderDAO

public void setWatchedFolderDAO(WatchedFolderDAO watchedFolderDAO)
The watched folders DAO used in this service

Parameters:
watchedFolderDAO - the watched files DAO

getWatchedFolderById

public WebWatchedFolder getWatchedFolderById(java.lang.Long folderId)
Description copied from interface: WatchedFolderService
Gets a watched folder by ID

Specified by:
getWatchedFolderById in interface WatchedFolderService
Parameters:
folderId - the watched folder ID
Returns:
the watched folder
See Also:
WatchedFolderService.getWatchedFolderById(Long)

refreshWatchedFilesInWatchedFolder

public void refreshWatchedFilesInWatchedFolder(java.lang.Long folderId)
Description copied from interface: WatchedFolderService
Refreshes the files present in the given folder

Specified by:
refreshWatchedFilesInWatchedFolder in interface WatchedFolderService
Parameters:
folderId - the watched folder ID
See Also:
WatchedFolderService.refreshWatchedFilesInWatchedFolder(Long)

setFileSystemDAO

public void setFileSystemDAO(FileSystemDAO fileSystemDAO)
The file system DAO used in this service

Parameters:
fileSystemDAO - the fileSystemDAO to set

deleteWatchedFolder

public void deleteWatchedFolder(java.lang.Long folderId)
Description copied from interface: WatchedFolderService
Deletes the given watched folder

Specified by:
deleteWatchedFolder in interface WatchedFolderService
Parameters:
folderId - the watched folder ID
See Also:
WatchedFolderService.deleteWatchedFolder(Long)

setWatcherTaskService

public void setWatcherTaskService(WatcherTaskService watcherTaskService)
The service used to create new task

Parameters:
taskTaskService - the taskTaskService to set


Copyright © 2009. All Rights Reserved.