Examples of Dbt


Examples of com.sleepycat.db.Dbt

    public ActiveMQMessage getMessage(MessageIdentity identity) throws JMSException {
        String messageID = identity.getMessageID();
        ActiveMQMessage answer = null;
        try {
            Dbt key = createKey(messageID);
            Dbt value = new Dbt();
            if (database.get(null, key, value, 0) == SUCCESS) {
                answer = extractMessage(value);
            }
            return answer;
        }
View Full Code Here

Examples of com.sleepycat.db.Dbt


    // Implementation methods
    //-------------------------------------------------------------------------
    protected Dbt createKey(String messageID) {
        Dbt key = new Dbt(asBytes(messageID));
        return key;
    }
View Full Code Here

Examples of com.sleepycat.db.Dbt

    }

    public MessageIdentity addMessage(ActiveMQMessage message) throws JMSException {
        String messageID = message.getJMSMessageID();
        try {
            Dbt key = createKey(messageID);
            Dbt value = new Dbt(asBytes(message));
            database.put(BDbHelper.getTransaction(), key, value, 0);
            return new MessageIdentity(messageID);
        }
        catch (DbException e) {
            throw JMSExceptionHelper.newJMSException("Failed to broker message: " + messageID + " in container: " + e, e);
View Full Code Here

Examples of com.sleepycat.db.Dbt

    public ActiveMQMessage getMessage(MessageIdentity identity) throws JMSException {
        String messageID = identity.getMessageID();
        ActiveMQMessage answer = null;
        try {
            Dbt key = createKey(messageID);
            Dbt value = new Dbt();
            if (database.get(null, key, value, 0) == SUCCESS) {
                answer = extractMessage(value);
            }
            return answer;
        }
View Full Code Here

Examples of com.sleepycat.db.Dbt


    // Implementation methods
    //-------------------------------------------------------------------------
    protected Dbt createKey(String messageID) {
        Dbt key = new Dbt(asBytes(messageID));
        return key;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.