Class MessagePersister
java.lang.Object
org.apache.activemq.artemis.spi.core.protocol.MessagePersister
- All Implemented Interfaces:
org.apache.activemq.artemis.core.persistence.Persister<org.apache.activemq.artemis.api.core.Message>
public class MessagePersister
extends Object
implements org.apache.activemq.artemis.core.persistence.Persister<org.apache.activemq.artemis.api.core.Message>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidorg.apache.activemq.artemis.api.core.Messagedecode(org.apache.activemq.artemis.api.core.ActiveMQBuffer buffer, org.apache.activemq.artemis.api.core.Message record, org.apache.activemq.artemis.core.persistence.CoreMessageObjectPools pools) org.apache.activemq.artemis.api.core.Messagedecode(org.apache.activemq.artemis.api.core.ActiveMQBuffer buffer, org.apache.activemq.artemis.api.core.Message record, org.apache.activemq.artemis.core.persistence.CoreMessageObjectPools pools, org.apache.activemq.artemis.core.persistence.StorageManager storageManager) voidencode(org.apache.activemq.artemis.api.core.ActiveMQBuffer buffer, org.apache.activemq.artemis.api.core.Message record) Sub classes must add the first short as the protocol-idintgetEncodeSize(org.apache.activemq.artemis.api.core.Message record) bytegetID()static MessagePersisterstatic org.apache.activemq.artemis.core.persistence.PersistergetPersister(byte id) static voidregisterPersister(org.apache.activemq.artemis.core.persistence.Persister<org.apache.activemq.artemis.api.core.Message> persister) static voidregisterProtocol(ProtocolManagerFactory manager)
-
Constructor Details
-
MessagePersister
protected MessagePersister()
-
-
Method Details
-
getID
public byte getID()- Specified by:
getIDin interfaceorg.apache.activemq.artemis.core.persistence.Persister<org.apache.activemq.artemis.api.core.Message>
-
registerProtocol
-
clearPersisters
public static void clearPersisters() -
getPersister
public static org.apache.activemq.artemis.core.persistence.Persister getPersister(byte id) -
registerPersister
public static void registerPersister(org.apache.activemq.artemis.core.persistence.Persister<org.apache.activemq.artemis.api.core.Message> persister) -
getInstance
-
getEncodeSize
public int getEncodeSize(org.apache.activemq.artemis.api.core.Message record) - Specified by:
getEncodeSizein interfaceorg.apache.activemq.artemis.core.persistence.Persister<org.apache.activemq.artemis.api.core.Message>
-
encode
public void encode(org.apache.activemq.artemis.api.core.ActiveMQBuffer buffer, org.apache.activemq.artemis.api.core.Message record) Sub classes must add the first short as the protocol-id- Specified by:
encodein interfaceorg.apache.activemq.artemis.core.persistence.Persister<org.apache.activemq.artemis.api.core.Message>
-
decode
public org.apache.activemq.artemis.api.core.Message decode(org.apache.activemq.artemis.api.core.ActiveMQBuffer buffer, org.apache.activemq.artemis.api.core.Message record, org.apache.activemq.artemis.core.persistence.CoreMessageObjectPools pools) - Specified by:
decodein interfaceorg.apache.activemq.artemis.core.persistence.Persister<org.apache.activemq.artemis.api.core.Message>
-
decode
public org.apache.activemq.artemis.api.core.Message decode(org.apache.activemq.artemis.api.core.ActiveMQBuffer buffer, org.apache.activemq.artemis.api.core.Message record, org.apache.activemq.artemis.core.persistence.CoreMessageObjectPools pools, org.apache.activemq.artemis.core.persistence.StorageManager storageManager)
-