org.aludratest.service.file.impl
Class FileServiceImpl

java.lang.Object
  extended by org.aludratest.service.AbstractAludraService
      extended by org.aludratest.service.AbstractConfigurableAludraService
          extended by org.aludratest.service.file.impl.FileServiceImpl
All Implemented Interfaces:
Closeable, Configurable, AludraCloseable, AludraService, FileService

public class FileServiceImpl
extends AbstractConfigurableAludraService
implements FileService

Implements the FileService interface.

Author:
Volker Bergmann

Field Summary
 
Fields inherited from class org.aludratest.service.AbstractAludraService
aludraServiceContext
 
Constructor Summary
FileServiceImpl()
          Default constructor.
 
Method Summary
 FileCondition check()
          Provides the service's checking operations.
 void close()
          Closes the configuration (and with it, Commons VFS' StandardFileSystemManager).
 void configure(Preferences preferences)
          Called by the framework to let a configurable object configure itself according to the passed Preferences object.
 String getDescription()
          Provides a textual description of the most important configuration information to be logged when the service is configured.
 String getPropertiesBaseName()
          Returns the base name for properties files for this configurable, e.g.
 void initService()
          Abstract initialization method to be implemented by child classes for individual initialization operations.
 FileInteraction perform()
          Provides the service's interaction operations.
 FileVerification verify()
          Provides the service's verification operations.
 
Methods inherited from class org.aludratest.service.AbstractConfigurableAludraService
fillDefaults, getDefaultsResourceName
 
Methods inherited from class org.aludratest.service.AbstractAludraService
getInstanceName, init, setSystemConnector, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.aludratest.service.AludraService
getInstanceName, init, setSystemConnector
 

Constructor Detail

FileServiceImpl

public FileServiceImpl()
Default constructor.

Method Detail

getPropertiesBaseName

public String getPropertiesBaseName()
Description copied from interface: Configurable
Returns the base name for properties files for this configurable, e.g. "aludratest" if the properties files are named "aludratest.properties", or "fileService" for "fileService.properties".

Specified by:
getPropertiesBaseName in interface Configurable
Returns:
The base name for properties files for this configurable, never null.

configure

public void configure(Preferences preferences)
               throws AutomationException
Description copied from interface: Configurable
Called by the framework to let a configurable object configure itself according to the passed Preferences object. The object is allowed to store the passed Preferences reference and query it for configuration parameters when needed. It is also OK to extract all required parameters in this method.
In any case, this method should check the configuration for validness and throw an AutomationException when the configuration is invalid.

Specified by:
configure in interface Configurable
Parameters:
preferences - Configuration object for this configurable.
Throws:
AutomationException - If the configuration contains invalid elements.

initService

public void initService()
Description copied from class: AbstractAludraService
Abstract initialization method to be implemented by child classes for individual initialization operations. Implementors can access the protected aludraServiceContext field to retrieve instances of other services, if required.

Specified by:
initService in class AbstractAludraService

close

public void close()
Closes the configuration (and with it, Commons VFS' StandardFileSystemManager).

Specified by:
close in interface Closeable
Specified by:
close in interface AludraCloseable

perform

public FileInteraction perform()
Provides the service's interaction operations.

Specified by:
perform in interface AludraService
Specified by:
perform in interface FileService
Returns:
the service's Interaction object
See Also:
AludraService.perform()

verify

public FileVerification verify()
Provides the service's verification operations.

Specified by:
verify in interface AludraService
Specified by:
verify in interface FileService
Returns:
the service's Verification object
See Also:
AludraService.verify()

check

public FileCondition check()
Provides the service's checking operations.

Specified by:
check in interface AludraService
Specified by:
check in interface FileService
Returns:
the service's Condition object
See Also:
AludraService.check()

getDescription

public String getDescription()
Description copied from interface: AludraService
Provides a textual description of the most important configuration information to be logged when the service is configured.

Specified by:
getDescription in interface AludraService
Returns:
a textual description of the most important configuration information


Copyright © 2015 aludratest.org. All rights reserved.