Uses of Class
it.polimi.ingsw.communication.sugar_framework.Peer
Packages that use Peer
Package
Description
-
Uses of Peer in it.polimi.ingsw.communication.sugar_framework
Fields in it.polimi.ingsw.communication.sugar_framework with type parameters of type PeerMethods in it.polimi.ingsw.communication.sugar_framework that return types with arguments of type PeerMethods in it.polimi.ingsw.communication.sugar_framework with parameters of type PeerModifier and TypeMethodDescriptionvoidMakes the peer join into this roomprotected voidSugarServer.disconnectPeer(Peer peer) Disconnects the peer from the serverprotected abstract voidSugarServer.onPeerConnect(Peer peer) The server calls this function any time a peer connects to the serverprotected abstract voidSugarServer.onPeerDisconnect(Peer peer) The server calls this function any time a peer disconnects from the serverprotected abstract voidSugarServer.onPeerMessage(Peer peer, SugarMessage message) The server calls this function any time it receives a message from a peer.voidIf the peer is in this room, makes the peer leave the room, otherwise it has no effectvoidSugarServer.send(SugarMessage msg, Peer peer) Delivers the message to the peerprivate voidSend the UPI initial message to the peerMethod parameters in it.polimi.ingsw.communication.sugar_framework with type arguments of type PeerModifier and TypeMethodDescriptionvoidRoom.addPeers(Collection<Peer> peers) Adds all peers to the room -
Uses of Peer in it.polimi.ingsw.communication.sugar_framework.message_processing
Methods in it.polimi.ingsw.communication.sugar_framework.message_processing with parameters of type PeerModifier and TypeMethodDescriptionfinal SugarMessageSugarMessageProcessor.process(SugarMessage message, Peer sender) Executes all @SugarMessageHandler(s) annotated methods in this class that match this method's signature, if none is found, executes the "base()" method (if it exists)final SugarMessageSugarMessageProcessor.processFromLowerLayers(SugarMessage message, Peer receiver) -
Uses of Peer in it.polimi.ingsw.server.controller.auth_controller
Methods in it.polimi.ingsw.server.controller.auth_controller with parameters of type PeerModifier and TypeMethodDescriptionAuthController.base(SugarMessage message, Peer peer) AuthController.loginMsg(SugarMessage message, Peer peer) AuthController.signUpMsg(SugarMessage message, Peer peer) -
Uses of Peer in it.polimi.ingsw.server.controller.game_controller
Methods in it.polimi.ingsw.server.controller.game_controller that return types with arguments of type PeerModifier and TypeMethodDescriptionGameController.getPeerFromPlayer(@NotNull String username) Returns a peer associated to the username providedGameController.getTeamPeers(String username) Returns the peers of the player's teamMethods in it.polimi.ingsw.server.controller.game_controller with parameters of type PeerModifier and TypeMethodDescriptionGameController.base(SugarMessage message, Peer peer) booleanGameController.containsPeer(Peer peer) Return true if there is the player in the gamevoidGameController.setInactivePlayer(Peer peer) voidGameController.updatePeerIfOlder(@NotNull String username, @NotNull Peer peer) Used when a player plays a move, it checks if the user has logged In from a new connection, if yes, it updates the peer socket -
Uses of Peer in it.polimi.ingsw.server.controller.game_state_controller
Methods in it.polimi.ingsw.server.controller.game_state_controller with parameters of type PeerModifier and TypeMethodDescriptionvoidCommunicationController.base(SugarMessage message, Peer peer) ExpertCommunicationController.characterIndexArchipelagoMsg(CharacterIndexArchipelagoMsg message, Peer peer) This is the handler of the messages for the characters with ID 3 and 5.ExpertCommunicationController.characterIndexColorArchipelagoMsg(CharacterIndexColorArchipelagoMsg message, Peer peer) This is the handler of the messages for the characters with ID 1.ExpertCommunicationController.characterIndexColorListsMsg(CharacterIndexColorListsMsg message, Peer peer) This is the handler of the messages for the characters with ID 1.ExpertCommunicationController.characterIndexColorMsg(CharacterIndexColorMsg message, Peer peer) This is the handler of the messages for the characters with ID 9, 11 and 12.ExpertCommunicationController.characterIndexMsg(CharacterIndexMsg message, Peer peer) This is the handler of the messages for the characters with ID 2,4,6 and 8.CommunicationController.endTurnMsg(EndTurnMsg message, Peer peer) This method is the handler for the EndTurnMsgExpertCommunicationController.endTurnMsg(EndTurnMsg message, Peer peer) This is the handler of the messages for the characters with ID 1.CommunicationController.grabStudentsFromCloudMsg(GrabStudentsFromCloudMsg message, Peer peer) This method is the handler for the GrabStudentsFromCloudMsgCommunicationController.moveMotherNatureMsg(MoveMotherNatureMsg message, Peer peer) This method is the handler for the MoveMotherNatureMsgCommunicationController.moveStudentFromEntranceToArchipelagoMsg(MoveStudentFromEntranceToArchipelagoMsg message, Peer peer) This method is the handler for the MoveStudentFromEntranceToArchipelagoMsgCommunicationController.moveStudentFromEntranceToDiningRoomMsg(MoveStudentFromEntranceToDiningRoomMsg message, Peer peer) This method is the handler fot the MoveStudentFromEntranceToDiningRoomMsgCommunicationController.playCardMsg(PlayCardMsg message, Peer peer) This method is the handler for the PlayCardMsgCommunicationController.rollbackMsg(RollbackMsg message, Peer peer) This method is the handler for the RollBackMsgExpertCommunicationController.rollbackMsg(RollbackMsg message, Peer peer) This is the handler of the messages for the characters with ID 1. -
Uses of Peer in it.polimi.ingsw.server.controller.games_manager
Methods in it.polimi.ingsw.server.controller.games_manager with parameters of type PeerModifier and TypeMethodDescriptionGamesManager.base(SugarMessage sugarMessage, Peer peer) voidGamesManager.baseLowerLayers(SugarMessage message, Peer receiver) voidGamesManager.chatMsg(SugarMessage message, Peer peer) Sends a chat message to other players It can send to another player in the same game, otherwise can multicast the message to the team, or to all the game's participantsprivate Optional<GameController>GamesManager.findGameInvolvingPeer(Peer peer) GamesManager.getGamesMsg(SugarMessage message, Peer peer) Returns the games where the user is playingGamesManager.joinMatchMakingMsg(SugarMessage message, Peer peer) Join MatchMaking Controller If a user is not in the matchmaking, it'll be added to the matchmaking list it does nothing if a user is already in the matchmaking, it will be added to the matchmaking with the newest configuration otherwisevoidGamesManager.okAndUpdateMsg(SugarMessage message, Peer receiver) voidGamesManager.peerDisconnectedFromGameMsg(SugarMessage message, Peer peer) If the users disconnects, it waits 30 seconds If the user reconnects to the server, the game will not be closed, will be closed otherwiseGamesManager.reJoinMsg(SugarMessage sugarMessage, Peer peer) private voidGamesManager.send(SugarMessage message, Peer peer) -
Uses of Peer in it.polimi.ingsw.server.model.game_logic.entities
Fields in it.polimi.ingsw.server.model.game_logic.entities declared as PeerConstructors in it.polimi.ingsw.server.model.game_logic.entities with parameters of type Peer -
Uses of Peer in it.polimi.ingsw.server.server_logic
Methods in it.polimi.ingsw.server.server_logic with parameters of type PeerModifier and TypeMethodDescriptionprotected voidGameServer.onPeerConnect(Peer peer) protected voidGameServer.onPeerDisconnect(Peer peer) protected voidGameServer.onPeerMessage(Peer peer, SugarMessage message)