Package com._1c.g5.v8.dt.md.api
Class BasicDbObjectBasedOnTask
java.lang.Object
com._1c.g5.v8.bm.integration.AbstractBmTask<org.eclipse.core.runtime.IStatus>
com._1c.g5.v8.bm.integration.BmBasicTask
com._1c.g5.v8.bm.integration.BmBasicTask2Collection<P1,P2>
com._1c.g5.v8.dt.md.api.AbstractMdObjectCollectionTask<MdObject,MdObject>
com._1c.g5.v8.dt.md.api.BasicDbObjectBasedOnTask
- All Implemented Interfaces:
IBmTask<org.eclipse.core.runtime.IStatus>
public abstract class BasicDbObjectBasedOnTask
extends AbstractMdObjectCollectionTask<MdObject,MdObject>
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedBasicDbObjectBasedOnTask(MdObject object, Collection<MdObject> objects, String template) Creates a newIBmTasksuccessor instance -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddBasedOn(MdObject target, Collection<MdObject> sources) Adds based-on objects to a target object.protected voidaddBasisFor(MdObject source, Collection<MdObject> targets) Adds a source object to each of specified targets.static BasicDbObjectBasedOnTaskcreateBasedOnAddTask(MdObject dbObject, Collection<MdObject> dbObjects) Creates a newIBmTaskthat adds the givenBasicDbObjects to the based on collection.static BasicDbObjectBasedOnTaskcreateBasedOnRemoveTask(MdObject dbObject, Collection<MdObject> dbObjects) Creates a newIBmTaskthat removes the givenBasicDbObjects from the based on collection.static BasicDbObjectBasedOnTaskcreateBasisForAddTask(MdObject dbObject, Collection<MdObject> dbObjects) Creates a newIBmTaskthat adds the givenBasicDbObjectto each element of the collection.static BasicDbObjectBasedOnTaskcreateBasisForRemoveTask(MdObject dbObject, Collection<MdObject> dbObjects) Creates a newIBmTaskthat removes the givenBasicDbObjectfrom the each element of the collection.protected voidremoveBasedOn(MdObject target, Collection<MdObject> sources) Removes based-on objects from a target object.protected voidremoveBasisFor(MdObject source, Collection<MdObject> targets) Removes based-on objects from a target object.Methods inherited from class com._1c.g5.v8.dt.md.api.AbstractMdObjectCollectionTask
doExecute, execute, getNameMethods inherited from class com._1c.g5.v8.bm.integration.BmBasicTask2Collection
executeMethods inherited from class com._1c.g5.v8.bm.integration.BmBasicTask
execute, getTransactionMethods inherited from class com._1c.g5.v8.bm.integration.AbstractBmTask
getId, getName, getServiceId
-
Constructor Details
-
BasicDbObjectBasedOnTask
Creates a newIBmTasksuccessor instance- Parameters:
object- is theBasicDbObjectobjects- is the collection ofBasicDbObjectstemplate- is template message for task naming purposes
-
-
Method Details
-
createBasedOnAddTask
public static BasicDbObjectBasedOnTask createBasedOnAddTask(MdObject dbObject, Collection<MdObject> dbObjects) Creates a newIBmTaskthat adds the givenBasicDbObjects to the based on collection.- Parameters:
dbObject- is theBasicDbObjectdbObjects- is the collection ofBasicDbObject- Returns:
- the created task
-
createBasisForAddTask
public static BasicDbObjectBasedOnTask createBasisForAddTask(MdObject dbObject, Collection<MdObject> dbObjects) Creates a newIBmTaskthat adds the givenBasicDbObjectto each element of the collection.- Parameters:
dbObject- is theBasicDbObjectdbObjects- is the collection ofBasicDbObject- Returns:
- the created task
-
createBasedOnRemoveTask
public static BasicDbObjectBasedOnTask createBasedOnRemoveTask(MdObject dbObject, Collection<MdObject> dbObjects) Creates a newIBmTaskthat removes the givenBasicDbObjects from the based on collection.- Parameters:
dbObject- is theBasicDbObjectthat is based on the specified objects indbObjectsbased, cannot benulldbObjects- is the collection ofBasicDbObject, cannot benullor empty- Returns:
- the created task, never
null
-
createBasisForRemoveTask
public static BasicDbObjectBasedOnTask createBasisForRemoveTask(MdObject dbObject, Collection<MdObject> dbObjects) Creates a newIBmTaskthat removes the givenBasicDbObjectfrom the each element of the collection.- Parameters:
dbObject- is theBasicDbObjectthat is basis for the specified objects indbObjects, cannot benulldbObjects- is the collection ofBasicDbObject, cannot benullor empty- Returns:
- the created task, never
null
-
addBasedOn
Adds based-on objects to a target object. Both source and target objects must be the one that supports based on functionality (BasicDbObject or Table)- Parameters:
target- The target object to add. Cannot benullsources- The collection of objects to add. Cannot benull
-
addBasisFor
Adds a source object to each of specified targets. Both source and target objecgts must be the one that supports based on functionality (BasicDbObject or Table)- Parameters:
source- The target object to add. Cannot benulltargets- The collection of objects to add. Cannot benull
-
removeBasedOn
Removes based-on objects from a target object. A target object must be the one that supports based on functionality (BasicDbObject or Table)- Parameters:
target- The target object to add. Cannot benullsources- The collection of objects to add. Cannot benull
-
removeBasisFor
Removes based-on objects from a target object. A target object must be the one that supports based on functionality (BasicDbObject or Table)- Parameters:
source- The source object to remove. Cannot benulltargets- The collection of objects to remove source from. Cannot benull
-