Interface IAttachmentSerializer<S extends Tag,T> 
- Type Parameters:
 S- ATagsubclass: the serialized representation.T- The type of the data attachment.
public interface IAttachmentSerializer<S extends Tag,T> 
Serializer for data attachments.
 
The read(IAttachmentHolder, Tag) method must be implemented by subclasses!
- 
Method Summary
Modifier and TypeMethodDescriptiondefault Tread(IAttachmentHolder holder, S tag) Reads the attachment from NBT.default TDeprecated, for removal: This API element is subject to removal in a future version.Writes the attachment to NBT, or returns null if it is should not be serialized. 
- 
Method Details
- 
read
Deprecated, for removal: This API element is subject to removal in a future version.Implementread(IAttachmentHolder, Tag)instead. This method will be removed in a future version. - 
read
Reads the attachment from NBT.In a future version, the default implementation will be removed, but for now it exists for backwards compatibility with
read(Tag).- Parameters:
 holder- the holder for the attachment, can be cast if the subtype is knowntag- the serialized attachment
 - 
write
Writes the attachment to NBT, or returns null if it is should not be serialized. 
 - 
 
read(IAttachmentHolder, Tag)instead.