1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.aludratest.service.file;
17
18 import org.aludratest.config.ConfigProperties;
19 import org.aludratest.config.ConfigProperty;
20 import org.aludratest.service.AludraService;
21 import org.aludratest.service.ServiceInterface;
22
23
24
25
26 @ServiceInterface(name = "File Service", description = "Offers file related access and verifaction methods.")
27 @ConfigProperties({
28 @ConfigProperty(name = "protocol", type = String.class, description = "The name of the used protocol: file, ftp, sftp, http or https.", defaultValue = "file", required = true),
29 @ConfigProperty(name = "base.url", type = String.class, description = "The base URL of the service. On a local filesystem, this is a folder path.", defaultValue = "${user.home}", required = true),
30 @ConfigProperty(name = "encoding", type = String.class, description = "The encoding to use when reading / writing text files.", defaultValue = "UTF-8", required = true),
31 @ConfigProperty(name = "linefeed", type = String.class, description = "The line feed to use when reading / writing text files. Can be WINDOWS or UNIX", defaultValue = "UNIX", required = true),
32 @ConfigProperty(name = "writing.permitted", type = boolean.class, description = "Activates a \"write lock\" if set to false, so all modification operations on this file system will fail.", defaultValue = "false", required = true),
33 @ConfigProperty(name = "user", type = String.class, description = "The user name to use for login purposes (unused for file protocol)", required = false),
34 @ConfigProperty(name = "password", type = String.class, description = "The password to use for login purposes (unused for file protocol)", required = false) })
35 public interface FileService extends AludraService {
36
37
38 @Override
39 FileInteraction perform();
40
41
42 @Override
43 FileVerification verify();
44
45
46 @Override
47 FileCondition check();
48
49 }