org.zanata.client.commands.push
Class PushCommand
java.lang.Object
org.zanata.client.commands.ConfigurableCommand<O>
org.zanata.client.commands.ConfigurableProjectCommand<O>
org.zanata.client.commands.PushPullCommand<PushOptions>
org.zanata.client.commands.push.PushCommand
- All Implemented Interfaces:
- ZanataCommand
public class PushCommand
- extends PushPullCommand<PushOptions>
- Author:
- Sean Flanigan sflaniga@redhat.com
|
Method Summary |
protected List<String> |
getObsoleteDocNamesForProjectIterationFromServer()
gets doc list from server, returns a list of qualified doc names from
obsolete modules, or from no module. |
static void |
logOptions(org.slf4j.Logger logger,
PushOptions opts)
|
void |
run()
Executes the command, using the parameters which have been
previously set. |
List<org.zanata.rest.dto.resource.TranslationsResource> |
splitIntoBatch(org.zanata.rest.dto.resource.TranslationsResource doc,
int maxBatchSize)
Split TranslationsResource into List<TranslationsResource> according to
maxBatchSize, but only if mergeType=AUTO |
| Methods inherited from class org.zanata.client.commands.PushPullCommand |
belongsToCurrentModule, confirmWithUser, debug, expectYes, getDocListForProjectIterationFromServer, getLocaleMapList, getQualifiedDocNamesForCurrentModuleFromServer, loadETagCache, qualifiedDocName, storeETagCache, unqualifiedDocName |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PushCommand
public PushCommand(PushOptions opts)
PushCommand
public PushCommand(PushOptions opts,
ZanataProxyFactory factory,
ISourceDocResource sourceDocResource,
ITranslatedDocResource translationResources,
URI uri)
logOptions
public static void logOptions(org.slf4j.Logger logger,
PushOptions opts)
run
public void run()
throws Exception
- Description copied from interface:
ZanataCommand
- Executes the command, using the parameters which have been
previously set. This method must be called after initConfig().
- Throws:
Exception
getObsoleteDocNamesForProjectIterationFromServer
protected List<String> getObsoleteDocNamesForProjectIterationFromServer()
- gets doc list from server, returns a list of qualified doc names from
obsolete modules, or from no module.
splitIntoBatch
public List<org.zanata.rest.dto.resource.TranslationsResource> splitIntoBatch(org.zanata.rest.dto.resource.TranslationsResource doc,
int maxBatchSize)
- Split TranslationsResource into List<TranslationsResource> according to
maxBatchSize, but only if mergeType=AUTO
- Parameters:
doc - maxBatchSize -
- Returns:
- list of TranslationsResource, each containing up to maxBatchSize TextFlowTargets
Copyright © 2013 Zanata Project. All Rights Reserved.