Package com._1c.g5.v8.derived.context
Class PartBasedObjectContext
- java.lang.Object
- 
- com._1c.g5.v8.derived.context.BasicObjectContext
- 
- com._1c.g5.v8.derived.context.PartBasedObjectContext
 
 
- 
- All Implemented Interfaces:
- IObjectDerivedDataContext,- IPartBasedObjectContext
 - Direct Known Subclasses:
- FormExtContext,- ModelUpdaterContext
 
 public class PartBasedObjectContext extends BasicObjectContext implements IPartBasedObjectContext Standard implementation of thePartBasedObjectContextbased on the DD part concept. Each DD part corresponds to a single DD calculation procedure performed by a complex DD part computer.
- 
- 
Constructor SummaryConstructors Constructor Description PartBasedObjectContext(long bmObjectId, org.eclipse.emf.ecore.EClass eClass, String segmentId, Object computationCause)Creates a new instance of the context.PartBasedObjectContext(Object objectId, org.eclipse.emf.ecore.EClass eClass, String segmentId, Object computationCause)Creates a new instance of the context.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddParts(String... parts)voidaddParts(Collection<String> parts)Adds new DD parts to the context.protected voidclearExtendedData()Cleans extended data of the context on full rebuild to free the resourcesprotected voidcopyExtendedDataForContainments(PartBasedContainmentContext sourceContext, PartBasedContainmentContext destinationContext)Copies extended data of the containment contextprotected PartBasedContainmentContextcreatePartBasedContainmentContext(long bmObjectId, org.eclipse.emf.ecore.EClass eClass)Creates a corresponding part-based containment context.PartBasedContainmentContextgetContainmentContext(long bmObjectId, org.eclipse.emf.ecore.EClass eClass)Gets context for the containment object.PartBasedContainmentContextgetContainmentContext(IBmObject bmObject)Gets context for the containment object.Collection<PartBasedContainmentContext>getContainmentContexts()Gets the collection containment contexts associated with this context.Set<String>getParts()Gets the set of DD parts being collected within this context.voidloadData(IContextDataInput dataInput)Loads previously stored data into this contextprotected booleanmergeContainmentExtendedDataUpdates(PartBasedContainmentContext sourceContext, PartBasedContainmentContext destinationContext)Merges the containment context extended dataprotected booleanmergeExtendedDataUpdates(IObjectDerivedDataContext context)Merges extended data updates.booleanmergeUpdates(IObjectDerivedDataContext context)Merges updates into the context.voidsaveData(IContextDataOutput dataOutput)Saves data of this context to an external storagevoidsetFullRebuild(boolean fullRebuild)Sets/resets the full rebuild designator for the context object DD.- 
Methods inherited from class com._1c.g5.v8.derived.context.BasicObjectContextgetBmObjectId, getComputationCause, getEClass, getObjectId, getSegmentId, getTransactionHandle, getVersion, isFullRebuild, setTransactionHandle, setVersion
 
- 
 
- 
- 
- 
Constructor Detail- 
PartBasedObjectContextpublic PartBasedObjectContext(long bmObjectId, org.eclipse.emf.ecore.EClass eClass, String segmentId, Object computationCause)Creates a new instance of the context.- Parameters:
- bmObjectId- The identifier of the top BM object this context corresponds to
- eClass- The EClass of the of the top BM object this context corresponds to
- segmentId- The identifier of DD segment this context belongs to
- computationCause- The identifier of the sync. session
 
 - 
PartBasedObjectContextpublic PartBasedObjectContext(Object objectId, org.eclipse.emf.ecore.EClass eClass, String segmentId, Object computationCause) Creates a new instance of the context.- Parameters:
- bmObjectId- The identifier of the top BM object this context corresponds to
- eClass- The EClass of the of the top BM object this context corresponds to
- segmentId- The identifier of DD segment this context belongs to
- computationCause- The identifier of the sync. session
 
 
- 
 - 
Method Detail- 
addPartspublic void addParts(Collection<String> parts) Adds new DD parts to the context.- Parameters:
- parts- The DD part set that should be calculated for the object.
 
 - 
addPartspublic void addParts(String... parts) 
 - 
getContainmentContextpublic PartBasedContainmentContext getContainmentContext(IBmObject bmObject) Gets context for the containment object.- Parameters:
- bmObject- The object to get context for.
- Returns:
- The specific containment context.
 
 - 
getContainmentContextpublic PartBasedContainmentContext getContainmentContext(long bmObjectId, org.eclipse.emf.ecore.EClass eClass) Gets context for the containment object.- Parameters:
- bmObjectId- The BM object identifier to get context for.
- eClass- The- EClassof an object. May not be- null
- Returns:
- The specific containment context.
 
 - 
getContainmentContextspublic Collection<PartBasedContainmentContext> getContainmentContexts() Gets the collection containment contexts associated with this context.- Returns:
- The collection of containment contexts.
 
 - 
getPartspublic Set<String> getParts() Description copied from interface:IPartBasedObjectContextGets the set of DD parts being collected within this context.- Specified by:
- getPartsin interface- IPartBasedObjectContext
- Returns:
- The set of DD parts scheduled for the re-computation.
 
 - 
mergeUpdatespublic boolean mergeUpdates(IObjectDerivedDataContext context) Description copied from interface:IObjectDerivedDataContextMerges updates into the context. The base version of this context is being updated according to the verison of the provided context- Specified by:
- mergeUpdatesin interface- IObjectDerivedDataContext
- Parameters:
- context- The source of updates. Cannot be- null.
 
 - 
setFullRebuildpublic void setFullRebuild(boolean fullRebuild) Description copied from interface:IObjectDerivedDataContextSets/resets the full rebuild designator for the context object DD.- Specified by:
- setFullRebuildin interface- IObjectDerivedDataContext
- Overrides:
- setFullRebuildin class- BasicObjectContext
- Parameters:
- fullRebuild- Full rebuild flag.
 
 - 
clearExtendedDataprotected void clearExtendedData() Cleans extended data of the context on full rebuild to free the resources
 - 
copyExtendedDataForContainmentsprotected void copyExtendedDataForContainments(PartBasedContainmentContext sourceContext, PartBasedContainmentContext destinationContext) Copies extended data of the containment context- Parameters:
- sourceContext- Source context to copy data from. May not be- null
- destinationContext- Destination context to copy data to. May not be- null
 
 - 
createPartBasedContainmentContextprotected PartBasedContainmentContext createPartBasedContainmentContext(long bmObjectId, org.eclipse.emf.ecore.EClass eClass) Creates a corresponding part-based containment context. May be used to customize containment contexts in client applications- Parameters:
- bmObjectId- The BM object identifier to get context for.
- Returns:
- The context. May not be null
 
 - 
mergeContainmentExtendedDataUpdatesprotected boolean mergeContainmentExtendedDataUpdates(PartBasedContainmentContext sourceContext, PartBasedContainmentContext destinationContext) Merges the containment context extended data- Parameters:
- sourceContext- The source containment context. May not be- null
- destinationContext- The destination containment context. May not be- null
- Returns:
- True if there are changes in the destination context as a result of merge
 
 - 
mergeExtendedDataUpdatesprotected boolean mergeExtendedDataUpdates(IObjectDerivedDataContext context) Merges extended data updates.- Parameters:
- context- The context to get data from. May not be- null
- Returns:
- True if changes were made during the merge of the extended updates
 
 - 
saveDatapublic void saveData(IContextDataOutput dataOutput) throws IOException Description copied from interface:IObjectDerivedDataContextSaves data of this context to an external storage- Specified by:
- saveDatain interface- IObjectDerivedDataContext
- Parameters:
- dataOutput- The output stream to write data into. May not be- null
- Throws:
- IOException
 
 - 
loadDatapublic void loadData(IContextDataInput dataInput) throws IOException Description copied from interface:IObjectDerivedDataContextLoads previously stored data into this context- Specified by:
- loadDatain interface- IObjectDerivedDataContext
- Throws:
- IOException
 
 
- 
 
-