public class PortableContext extends Object implements Externalizable
| Constructor and Description |
|---|
PortableContext()
For
Externalizable. |
PortableContext(PortableMetaDataHandler metaHnd,
String gridName) |
public PortableContext()
Externalizable.public PortableContext(PortableMetaDataHandler metaHnd, @Nullable String gridName)
metaHnd - Meta data handler.gridName - Grid name.public void configure(PortableMarshaller marsh) throws PortableException
marsh - Portable marshaller.PortableException - In case of error.public PortableClassDescriptor descriptorForClass(Class<?> cls) throws PortableException
cls - Class.PortableException - In case of error.public PortableClassDescriptor descriptorForTypeId(boolean userType, int typeId, ClassLoader ldr)
userType - User type or not.typeId - Type ID.ldr - Class loader.public byte collectionType(Class<? extends Collection> cls)
cls - Collection class.public byte mapType(Class<? extends Map> cls)
cls - Map class.public int typeId(String typeName)
typeName - Type name.public int fieldId(int typeId,
String fieldName)
typeId - Type ID.fieldName - Field name.public PortableIdMapper idMapper(int typeId)
typeId - Type ID.public void writeExternal(ObjectOutput out) throws IOException
writeExternal in interface ExternalizableIOExceptionpublic void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
readExternal in interface ExternalizableIOExceptionClassNotFoundExceptionprotected Object readResolve() throws ObjectStreamException
ObjectStreamException - In case of error.public PortableClassDescriptor registerPredefinedType(Class<?> cls, int id)
cls - Class.id - Type ID.public void registerUserType(String clsName, PortableIdMapper idMapper, @Nullable PortableSerializer serializer, @Nullable String affKeyFieldName, boolean useTs, boolean metaDataEnabled, boolean keepDeserialized) throws PortableException
clsName - Class name.idMapper - ID mapper.serializer - Serializer.affKeyFieldName - Affinity key field name.useTs - Use timestamp flag.metaDataEnabled - Metadata enabled flag.keepDeserialized - Keep deserialized flag.PortableException - In case of error.@Nullable public PortableMetadata metaData(int typeId) throws PortableException
typeId - Type ID.PortableException - In case of error.public boolean isMetaDataEnabled(int typeId)
typeId - Type ID.public void updateMetaData(int typeId,
String typeName,
Map<String,String> fields)
throws PortableException
typeId - Type ID.typeName - Type name.fields - Fields map.PortableException - In case of error.public void updateMetaData(int typeId,
PortableMetaDataImpl meta)
throws PortableException
typeId - Type ID.meta - Meta data.PortableException - In case of error.public boolean isUseTimestamp()
public boolean isUseTimestamp(int typeId)
typeId - Type ID.public boolean isConvertString()
Follow @ApacheIgnite
Ignite Fabric : ver. 1.4.0 Release Date : September 24 2015