com.evolveum.midpoint.schema
Class DeltaConvertor

java.lang.Object
  extended by com.evolveum.midpoint.schema.DeltaConvertor

public class DeltaConvertor
extends Object

Author:
semancik

Field Summary
static QName PATH_ELEMENT_NAME
           
 
Constructor Summary
DeltaConvertor()
           
 
Method Summary
static
<V extends PrismValue>
ItemDelta<V>
createItemDelta(ItemDeltaType propMod, Class<? extends Objectable> objectType, PrismContext prismContext)
          Creates delta from PropertyModificationType (XML).
static
<V extends PrismValue>
ItemDelta<V>
createItemDelta(ItemDeltaType propMod, PrismContainerDefinition<?> pcDef)
           
static
<T extends Objectable>
ObjectDelta<T>
createObjectDelta(ObjectDeltaType objectDeltaType, PrismContext prismContext)
           
static
<T extends Objectable>
ObjectDelta<T>
createObjectDelta(ObjectModificationType objectModification, Class<T> type, PrismContext prismContext)
           
static
<T extends Objectable>
ObjectDelta<T>
createObjectDelta(ObjectModificationType objectModification, PrismObjectDefinition<T> objDef)
           
static
<T extends Objectable>
Collection<? extends ItemDelta>
toModifications(Collection<ItemDeltaType> itemDeltaTypes, PrismObjectDefinition<T> objDef)
           
static
<T extends Objectable>
Collection<? extends ItemDelta>
toModifications(ObjectModificationType objectModification, Class<T> type, PrismContext prismContext)
           
static
<T extends Objectable>
Collection<? extends ItemDelta>
toModifications(ObjectModificationType objectModification, PrismObjectDefinition<T> objDef)
           
static ObjectDeltaType toObjectDeltaType(ObjectDelta<? extends Objectable> objectDelta)
           
static
<T extends Objectable>
ObjectModificationType
toObjectModificationType(ObjectDelta<T> delta)
          Converts this delta to ObjectModificationType (XML).
static Collection<ItemDeltaType> toPropertyModificationTypes(ItemDelta delta)
          Converts this delta to PropertyModificationType (XML).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PATH_ELEMENT_NAME

public static final QName PATH_ELEMENT_NAME
Constructor Detail

DeltaConvertor

public DeltaConvertor()
Method Detail

createObjectDelta

public static <T extends Objectable> ObjectDelta<T> createObjectDelta(ObjectModificationType objectModification,
                                                                      Class<T> type,
                                                                      PrismContext prismContext)
                                                           throws SchemaException
Throws:
SchemaException

createObjectDelta

public static <T extends Objectable> ObjectDelta<T> createObjectDelta(ObjectModificationType objectModification,
                                                                      PrismObjectDefinition<T> objDef)
                                                           throws SchemaException
Throws:
SchemaException

createObjectDelta

public static <T extends Objectable> ObjectDelta<T> createObjectDelta(ObjectDeltaType objectDeltaType,
                                                                      PrismContext prismContext)
                                                           throws SchemaException
Throws:
SchemaException

toModifications

public static <T extends Objectable> Collection<? extends ItemDelta> toModifications(ObjectModificationType objectModification,
                                                                                     Class<T> type,
                                                                                     PrismContext prismContext)
                                                       throws SchemaException
Throws:
SchemaException

toModifications

public static <T extends Objectable> Collection<? extends ItemDelta> toModifications(ObjectModificationType objectModification,
                                                                                     PrismObjectDefinition<T> objDef)
                                                       throws SchemaException
Throws:
SchemaException

toModifications

public static <T extends Objectable> Collection<? extends ItemDelta> toModifications(Collection<ItemDeltaType> itemDeltaTypes,
                                                                                     PrismObjectDefinition<T> objDef)
                                                       throws SchemaException
Throws:
SchemaException

toObjectModificationType

public static <T extends Objectable> ObjectModificationType toObjectModificationType(ObjectDelta<T> delta)
                                                       throws SchemaException
Converts this delta to ObjectModificationType (XML).

Throws:
SchemaException

toObjectDeltaType

public static ObjectDeltaType toObjectDeltaType(ObjectDelta<? extends Objectable> objectDelta)
                                         throws SchemaException
Throws:
SchemaException

createItemDelta

public static <V extends PrismValue> ItemDelta<V> createItemDelta(ItemDeltaType propMod,
                                                                  Class<? extends Objectable> objectType,
                                                                  PrismContext prismContext)
                                                       throws SchemaException
Creates delta from PropertyModificationType (XML). The values inside the PropertyModificationType are converted to java. That's the reason this method needs schema and objectType (to locate the appropriate definitions).

Throws:
SchemaException

createItemDelta

public static <V extends PrismValue> ItemDelta<V> createItemDelta(ItemDeltaType propMod,
                                                                  PrismContainerDefinition<?> pcDef)
                                                       throws SchemaException
Throws:
SchemaException

toPropertyModificationTypes

public static Collection<ItemDeltaType> toPropertyModificationTypes(ItemDelta delta)
                                                             throws SchemaException
Converts this delta to PropertyModificationType (XML).

Throws:
SchemaException


Copyright © 2013 evolveum. All Rights Reserved.