public class NSDictionaryErsatz extends Ersatz
NSDictionary
instances and Ersatz
world.Modifier and Type | Method and Description |
---|---|
Iterable<EOAttribute> |
attributes()
Gets all EO attributes that this ersatz object has values stored for.
|
void |
delete()
This operation is unsupported as this ersatz implementation is not bound to any record store.
|
static NSDictionaryErsatz |
fromDictionary(NSDictionary<EOAttribute,Object> dict)
Creates ersatz based on values in the given dictionary.
|
static NSDictionaryErsatz |
full(EOEntity entity,
NSDictionary<String,Object> snapshot)
Creates ersatz representing all record EO attributes from the given EOF snapshot.
|
Object |
get(EOAttribute att)
Gets neutral value for an EO attribute.
|
static NSDictionaryErsatz |
partial(EOEntity entity,
NSDictionary<String,Object> snapshot)
Creates ersatz representing partial value of a record from the given partial EOF snapshot.
|
void |
put(EOAttribute att,
Object value)
Sets neutral java value for an EO attribute.
|
void |
remove(EOAttribute att)
Clears value for an EO attribute.
|
static NSMutableDictionary<String,Object> |
toSnapshot(Ersatz ersatz)
Creates EOF snapshot for the given ersatz.
|
public static NSDictionaryErsatz full(EOEntity entity, NSDictionary<String,Object> snapshot)
entity
- entity that the record represented by this ersatz comes fromsnapshot
- EOF record snapshotpublic static NSDictionaryErsatz partial(EOEntity entity, NSDictionary<String,Object> snapshot)
entity
- entity that the record represented by this ersatz comes fromsnapshot
- partial EOF record snapshotpublic static NSDictionaryErsatz fromDictionary(NSDictionary<EOAttribute,Object> dict)
dict
- record snapshotpublic static NSMutableDictionary<String,Object> toSnapshot(Ersatz ersatz)
ersatz
- ersatz to create EOF snapshot forpublic Iterable<EOAttribute> attributes()
Ersatz
attributes
in class Ersatz
public Object get(EOAttribute att)
Ersatz
Ersatz.attributes()
.public void put(EOAttribute att, Object value)
Ersatz
public void remove(EOAttribute att)
Ersatz
Copyright © 2002 – 2024 Project Wonder.