Пример #1
0
        private RoomPrx CreateNewRoomProxies(string nick, string topic, ListenerPrx listener)
        {
            RoomI room = new RoomI(topic);

            room.AddListener(nick, listener);
            RoomPrx roomPrx = RoomPrxHelper.uncheckedCast(this.Adapter.addWithUUID(room));

            RoomAdmI roomAdm = new RoomAdmI(topic);

            roomAdm.AddListener(nick, listener);
            RoomAdmTie_ roomAdmTie = new RoomAdmTie_(roomAdm);

            this.Adapter.addFacet(roomAdmTie, roomPrx.ice_getIdentity(), "V1");

            RoomV2I roomV2 = new RoomV2I(topic);

            roomV2.AddListener(nick, listener);
            this.Adapter.addFacet(roomV2, roomPrx.ice_getIdentity(), "V2");

            this._rooms.Add(topic, roomPrx);
            return(roomPrx);
        }
Пример #2
0
        private RoomPrx CreateNewRoomProxies(string nick, string topic, ListenerPrx listener)
        {
            RoomI room = new RoomI(topic);
            room.AddListener(nick, listener);
            RoomPrx roomPrx = RoomPrxHelper.uncheckedCast(this.Adapter.addWithUUID(room));

            RoomAdmI roomAdm = new RoomAdmI(topic);
            roomAdm.AddListener(nick, listener);
            RoomAdmTie_ roomAdmTie = new RoomAdmTie_(roomAdm);
            this.Adapter.addFacet(roomAdmTie, roomPrx.ice_getIdentity(), "V1");

            RoomV2I roomV2 = new RoomV2I(topic);
            roomV2.AddListener(nick, listener);
            this.Adapter.addFacet(roomV2, roomPrx.ice_getIdentity(), "V2");

            this._rooms.Add(topic, roomPrx);
            return roomPrx;
        }