public class TransferServiceImpl2 extends Object implements TransferService2
Constructor and Description |
---|
TransferServiceImpl2() |
Modifier and Type | Method and Description |
---|---|
void |
cancelAsync(String transferHandle)
CancelAsync
|
TransferTarget |
createAndSaveTransferTarget(String name,
String title,
String description,
String endpointProtocol,
String endpointHost,
int endpointPort,
String endpointPath,
String username,
char[] password)
create transfer target
|
TransferTarget |
createTransferTarget(String name)
Create a new in memory transfer target
|
void |
deleteTransferTarget(String name)
Delete a transfer target.
|
void |
enableTransferTarget(String name,
boolean enable)
Enables/Disables the named transfer target
|
protected org.alfresco.service.cmr.repository.NodeRef |
getDefaultGroup() |
protected org.alfresco.service.cmr.repository.NodeRef |
getTransferHome() |
TransferTarget |
getTransferTarget(String name)
Get a transfer target by its name
|
Set<TransferTarget> |
getTransferTargets()
Get all transfer targets
|
Set<TransferTarget> |
getTransferTargets(String groupName)
Get all transfer targets in the specified group
|
TransferTransmitter |
getTransmitter() |
void |
init() |
TransferTarget |
saveTransferTarget(TransferTarget update)
create or update a transfer target.
|
void |
setActionService(ActionService actionService) |
void |
setCommitPollDelay(long commitPollDelay) |
void |
setDefaultTransferGroup(String defaultGroup) |
void |
setDescriptorService(DescriptorService descriptorService) |
void |
setNamespaceService(org.alfresco.service.namespace.NamespaceService namespaceService) |
void |
setNodeService(org.alfresco.service.cmr.repository.NodeService nodeService) |
void |
setSearchService(org.alfresco.service.cmr.search.SearchService searchService) |
void |
setSingletonCache(org.alfresco.repo.cache.SimpleCache<String,org.alfresco.service.cmr.repository.NodeRef> singletonCache) |
void |
setTransactionService(TransactionService transactionService) |
void |
setTransferManifestNodeFactory(TransferManifestNodeFactory transferManifestNodeFactory) |
void |
setTransferReporter(TransferReporter transferReporter) |
void |
setTransferSpaceQuery(String transferSpaceQuery) |
void |
setTransferVersionChecker(TransferVersionChecker transferVersionChecker) |
void |
setTransmitter(TransferTransmitter transmitter) |
boolean |
targetExists(String name)
Test to see if the target with the specified name exists
|
TransferEndEvent |
transfer(String targetName,
TransferDefinition definition,
Collection<TransferCallback> callbacks)
Transfer Synchronous
|
TransferEndEvent |
transfer(String targetName,
TransferDefinition definition,
TransferCallback... callbacks)
Transfer Synchronous
|
void |
transferAsync(String targetName,
TransferDefinition definition,
Collection<TransferCallback> callbacks)
Transfer async.
|
void |
transferAsync(String targetName,
TransferDefinition definition,
TransferCallback... callbacks)
Transfer async.
|
void |
verify(TransferTarget target)
Verify a target is available and that the configured credentials are valid.
|
public void init()
public TransferTarget createTransferTarget(String name)
createTransferTarget
in interface TransferService2
public TransferTarget createAndSaveTransferTarget(String name, String title, String description, String endpointProtocol, String endpointHost, int endpointPort, String endpointPath, String username, char[] password)
createAndSaveTransferTarget
in interface TransferService2
name
- the name of this transfer target, which must be uniquetitle
- the display name of this transfer targetdescription
- StringendpointProtocol
- either http or httpsendpointHost
- StringendpointPort
- intendpointPath
- Stringusername
- Stringpassword
- char[]protected org.alfresco.service.cmr.repository.NodeRef getDefaultGroup()
public Set<TransferTarget> getTransferTargets()
getTransferTargets
in interface TransferService2
public Set<TransferTarget> getTransferTargets(String groupName)
getTransferTargets
in interface TransferService2
groupName
- the name of the transfer grouppublic void deleteTransferTarget(String name)
TransferService2
deleteTransferTarget
in interface TransferService2
name
- the name of this transfer target,public void enableTransferTarget(String name, boolean enable)
enableTransferTarget
in interface TransferService2
name
- the name of the transfer targetenable
- (or false=disable)public boolean targetExists(String name)
TransferService2
targetExists
in interface TransferService2
name
- Stringpublic TransferTarget getTransferTarget(String name)
TransferService2
getTransferTarget
in interface TransferService2
public TransferTarget saveTransferTarget(TransferTarget update)
saveTransferTarget
in interface TransferService2
update
- TransferTargetpublic void transferAsync(String targetName, TransferDefinition definition, TransferCallback... callbacks)
transferAsync
in interface TransferService2
targetName
- Stringdefinition
- TransferDefinitioncallbacks
- TransferCallback...public void transferAsync(String targetName, TransferDefinition definition, Collection<TransferCallback> callbacks)
transferAsync
in interface TransferService2
targetName
- Stringdefinition
- TransferDefinitioncallbacks
- - a collection of callback handlers that will be called as transfer proceeds. May be null.public TransferEndEvent transfer(String targetName, TransferDefinition definition, TransferCallback... callbacks) throws TransferFailureException
transfer
in interface TransferService2
targetName
- Stringdefinition
- TransferDefinitioncallbacks
- TransferCallback...TransferFailureException
public TransferEndEvent transfer(String targetName, TransferDefinition definition, Collection<TransferCallback> callbacks) throws TransferFailureException
transfer
in interface TransferService2
targetName
- Stringdefinition
- TransferDefinitioncallbacks
- - a set of callback handlers that will be called as transfer proceeds. May be null.TransferFailureException
public void cancelAsync(String transferHandle)
cancelAsync
in interface TransferService2
transferHandle
- the unique identifier of the transfer to cancel.TransferEventBegin
public void setNodeService(org.alfresco.service.cmr.repository.NodeService nodeService)
public void setSearchService(org.alfresco.service.cmr.search.SearchService searchService)
public void setSingletonCache(org.alfresco.repo.cache.SimpleCache<String,org.alfresco.service.cmr.repository.NodeRef> singletonCache)
public void setTransferSpaceQuery(String transferSpaceQuery)
public void setDefaultTransferGroup(String defaultGroup)
public TransferTransmitter getTransmitter()
public void setTransmitter(TransferTransmitter transmitter)
protected org.alfresco.service.cmr.repository.NodeRef getTransferHome()
public void verify(TransferTarget target) throws TransferException
TransferService2
verify
in interface TransferService2
TransferException
public void setTransferManifestNodeFactory(TransferManifestNodeFactory transferManifestNodeFactory)
public void setActionService(ActionService actionService)
public void setTransactionService(TransactionService transactionService)
public void setTransferReporter(TransferReporter transferReporter)
public void setCommitPollDelay(long commitPollDelay)
public void setDescriptorService(DescriptorService descriptorService)
public void setTransferVersionChecker(TransferVersionChecker transferVersionChecker)
public void setNamespaceService(org.alfresco.service.namespace.NamespaceService namespaceService)
Copyright © 2005–2017 Alfresco Software. All rights reserved.