Обработка пакета 16 с пуш токенами
This commit is contained in:
@@ -9,6 +9,7 @@ import com.rosetta.im.executors.Executor0Handshake;
|
||||
import com.rosetta.im.executors.Executor10RequestUpdate;
|
||||
import com.rosetta.im.executors.Executor11Typeing;
|
||||
import com.rosetta.im.executors.Executor15RequestTransport;
|
||||
import com.rosetta.im.executors.Executor16PushNotification;
|
||||
import com.rosetta.im.executors.Executor1UserInfo;
|
||||
import com.rosetta.im.executors.Executor24DeviceResolve;
|
||||
import com.rosetta.im.executors.Executor3Search;
|
||||
@@ -27,6 +28,7 @@ import com.rosetta.im.packet.Packet0Handshake;
|
||||
import com.rosetta.im.packet.Packet10RequestUpdate;
|
||||
import com.rosetta.im.packet.Packet11Typeing;
|
||||
import com.rosetta.im.packet.Packet15RequestTransport;
|
||||
import com.rosetta.im.packet.Packet16PushNotification;
|
||||
import com.rosetta.im.packet.Packet1UserInfo;
|
||||
import com.rosetta.im.packet.Packet23DeviceList;
|
||||
import com.rosetta.im.packet.Packet24DeviceResolve;
|
||||
@@ -62,6 +64,17 @@ public class Boot {
|
||||
private Configuration configuration;
|
||||
private ServerConfiguration serverConfiguration;
|
||||
|
||||
/**
|
||||
* Конструктор по умолчанию, использует порт 3000 для сервера
|
||||
*/
|
||||
public Boot() {
|
||||
this(3000);
|
||||
}
|
||||
|
||||
/**
|
||||
* Инициализатор приложения
|
||||
* @param port Порт, на котором будет работать сервер. Если не указан, то будет использован порт 3000
|
||||
*/
|
||||
public Boot(int port) {
|
||||
this.packetManager = new PacketManager();
|
||||
this.eventManager = new EventManager();
|
||||
@@ -149,7 +162,11 @@ public class Boot {
|
||||
this.packetManager.registerPacket(9, Packet9DeviceNew.class);
|
||||
this.packetManager.registerPacket(10, Packet10RequestUpdate.class);
|
||||
this.packetManager.registerPacket(11, Packet11Typeing.class);
|
||||
//RESERVED 12 PACKET AVATAR (unused)
|
||||
//RESERVED 13 PACKET KERNEL UPDATE (unused)
|
||||
//RESERVED 14 PACKET APP UPDATE (unused)
|
||||
this.packetManager.registerPacket(15, Packet15RequestTransport.class);
|
||||
this.packetManager.registerPacket(16, Packet16PushNotification.class);
|
||||
this.packetManager.registerPacket(23, Packet23DeviceList.class);
|
||||
this.packetManager.registerPacket(24, Packet24DeviceResolve.class);
|
||||
|
||||
@@ -165,6 +182,7 @@ public class Boot {
|
||||
this.packetManager.registerExecutor(10, new Executor10RequestUpdate(this.serverConfiguration));
|
||||
this.packetManager.registerExecutor(11, new Executor11Typeing(this.clientManager, this.packetManager));
|
||||
this.packetManager.registerExecutor(15, new Executor15RequestTransport(this.serverConfiguration));
|
||||
this.packetManager.registerExecutor(16, new Executor16PushNotification());
|
||||
this.packetManager.registerExecutor(24, new Executor24DeviceResolve(this.clientManager, this.eventManager));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user