public class EObjectCollectibleCodec
extends java.lang.Object
CollectibleCodec for EObject's| Constructor and Description |
|---|
EObjectCollectibleCodec(DBObjectBuilder dbBuilder,
EObjectBuilder eoBuilder,
Resource resource) |
| Modifier and Type | Method and Description |
|---|---|
protected EObject |
createEObject(BsonReader reader,
ResourceSet resourceSet,
boolean readWithKey)
This function creates an empty EObject by extracting the EClass type from the given DBObject
using the ECLASS_KEY.
|
EObject |
decode(BsonReader reader,
DecoderContext decoderContext) |
boolean |
documentHasId(EObject document) |
void |
encode(BsonWriter writer,
EObject value,
EncoderContext encoderContext) |
EObject |
generateIdIfAbsentFromDocument(EObject document) |
BsonValue |
getDocumentId(EObject document) |
protected EClass |
getEClass(ResourceSet resourceSet,
java.lang.String eClassURI)
Finds the EClass for the given URI
|
java.lang.Class<EObject> |
getEncoderClass() |
public EObjectCollectibleCodec(DBObjectBuilder dbBuilder, EObjectBuilder eoBuilder, Resource resource)
public void encode(BsonWriter writer,
EObject value,
EncoderContext encoderContext)
public java.lang.Class<EObject> getEncoderClass()
public EObject decode(BsonReader reader,
DecoderContext decoderContext)
public EObject generateIdIfAbsentFromDocument(EObject document)
public boolean documentHasId(EObject document)
public BsonValue getDocumentId(EObject document)
protected EObject createEObject(BsonReader reader,
ResourceSet resourceSet,
boolean readWithKey)
reader - the BsonReader to read fromresourceSet - the resourceSet that will be used to locate the EClass if it is not cachedprotected EClass getEClass(ResourceSet resourceSet,
java.lang.String eClassURI)
resourceSet - the resource set used to locate the EClass if it was not
found in the cacheeClassURI - the URI of the EClassBryan Hunt, Data In Motion Consulting