示例#1
0
        public ActiveMQTempDestination CreateTemporaryDestination(bool topic)
        {
            ActiveMQTempDestination destination = null;

            if (topic)
            {
                destination = new ActiveMQTempTopic(
                    info.ConnectionId.Value + ":" + Interlocked.Increment(ref temporaryDestinationCounter));
            }
            else
            {
                destination = new ActiveMQTempQueue(
                    info.ConnectionId.Value + ":" + Interlocked.Increment(ref temporaryDestinationCounter));
            }

            DestinationInfo command = new DestinationInfo();

            command.ConnectionId  = ConnectionId;
            command.OperationType = DestinationInfo.ADD_OPERATION_TYPE;             // 0 is add
            command.Destination   = destination;

            this.SyncRequest(command);

            destination.Connection = this;
            this.AddTempDestination(destination);

            return(destination);
        }
示例#2
0
        public ITemporaryQueue CreateTemporaryQueue()
        {
            ActiveMQTempQueue answer = new ActiveMQTempQueue(connection.CreateTemporaryDestinationName());

            CreateTemporaryDestination(answer);
            return(answer);
        }
示例#3
0
        //
        // Write the booleans that this object uses to a BooleanStream
        //
        public override int TightMarshal1(OpenWireFormat wireFormat, Object o, BooleanStream bs)
        {
            ActiveMQTempQueue info = (ActiveMQTempQueue)o;

            int rc = base.TightMarshal1(wireFormat, info, bs);

            return(rc + 0);
        }