Class DefaultCallback
- java.lang.Object
-
- jetbrains.buildServer.serverSide.agent.DefaultCallback
-
- All Implemented Interfaces:
SAgentFileManager.Callback
public class DefaultCallback extends Object implements SAgentFileManager.Callback
Example usage:final DefaultCallback callback = new DefaultCallback(); myAgentFileManager.requestForFile(agentName, fileName, useCache, callback); new WaitFor() { @Override protected boolean condition() { return callback.isComplete(); } };
- Since:
- 6.0
- Author:
- Maxim Podkolzine (maxim.podkolzine@jetbrains.com)
-
-
Constructor Summary
Constructors Constructor Description DefaultCallback()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
error(String reason)
Is called in case of error.String
getError()
File
getFile()
boolean
isComplete()
void
success(File file)
Is called in case of success.
-
-
-
Method Detail
-
error
public void error(@NotNull String reason)
Description copied from interface:SAgentFileManager.Callback
Is called in case of error.- Specified by:
error
in interfaceSAgentFileManager.Callback
- Parameters:
reason
- error reason
-
success
public void success(@NotNull File file)
Description copied from interface:SAgentFileManager.Callback
Is called in case of success.- Specified by:
success
in interfaceSAgentFileManager.Callback
- Parameters:
file
- local file (or directory) requested
-
isComplete
public boolean isComplete()
-
getError
public String getError()
-
getFile
public File getFile()
-
-