Add: Added Coverage Screenshots And htlmReport.
This commit is contained in:
@@ -0,0 +1,102 @@
|
||||
|
||||
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html id="htmlId">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
|
||||
<title>Coverage Report > IClientCallback</title>
|
||||
<style type="text/css">
|
||||
@import "../../css/coverage.css";
|
||||
@import "../../css/idea.min.css";
|
||||
</style>
|
||||
<script type="text/javascript" src="../../js/highlight.min.js"></script>
|
||||
<script type="text/javascript" src="../../js/highlightjs-line-numbers.min.js"></script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div class="content">
|
||||
<div class="breadCrumbs">
|
||||
Current scope: <a href="../../index.html">all classes</a>
|
||||
<span class="separator">|</span>
|
||||
<a href="../index.html">it.polimi.ingsw.gc14.Network.RMI.Common</a>
|
||||
</div>
|
||||
|
||||
<h1>Coverage Summary for Class: IClientCallback (it.polimi.ingsw.gc14.Network.RMI.Common)</h1>
|
||||
|
||||
<table class="coverageStats">
|
||||
<tr>
|
||||
<th class="name">Class</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name">IClientCallback</td>
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
|
||||
<br/>
|
||||
<br/>
|
||||
|
||||
|
||||
<pre>
|
||||
<code class="sourceCode" id="sourceCode"> package it.polimi.ingsw.gc14.Network.RMI.Common;
|
||||
|
||||
import it.polimi.ingsw.gc14.Model.*;
|
||||
import it.polimi.ingsw.gc14.Network.NetworkEvent;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.rmi.*;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* Callback interface used by the server to notify an RMI client about
|
||||
* game updates and incoming network actions.
|
||||
*
|
||||
* <p>Implementations of this interface are remotely accessible and
|
||||
* serializable.
|
||||
*/
|
||||
public interface IClientCallback extends Remote, Serializable {
|
||||
|
||||
/**
|
||||
* Notifies the client that the game model has been initialized or updated.
|
||||
*
|
||||
* @param miniModel the current mini model of the game.
|
||||
* @throws RemoteException if an RMI communication error occurs.
|
||||
*/
|
||||
void onGameInit(MiniModel miniModel) throws RemoteException;
|
||||
|
||||
/**
|
||||
* Notifies the client about a network action to process.
|
||||
*
|
||||
* @param action the network event received from the server.
|
||||
* @throws RemoteException if an RMI communication error occurs.
|
||||
*/
|
||||
void onAction(NetworkEvent action) throws RemoteException;
|
||||
}
|
||||
</code>
|
||||
</pre>
|
||||
</div>
|
||||
|
||||
<script type="text/javascript">
|
||||
(function() {
|
||||
var msie = false, msie9 = false;
|
||||
/*@cc_on
|
||||
msie = true;
|
||||
@if (@_jscript_version >= 9)
|
||||
msie9 = true;
|
||||
@end
|
||||
@*/
|
||||
|
||||
if (!msie || msie && msie9) {
|
||||
hljs.highlightAll()
|
||||
hljs.initLineNumbersOnLoad();
|
||||
}
|
||||
})();
|
||||
</script>
|
||||
|
||||
<div class="footer">
|
||||
|
||||
<div style="float:right;">generated on 2026-06-14 21:53</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,174 @@
|
||||
|
||||
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html id="htmlId">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
|
||||
<title>Coverage Report > IGameServer</title>
|
||||
<style type="text/css">
|
||||
@import "../../css/coverage.css";
|
||||
@import "../../css/idea.min.css";
|
||||
</style>
|
||||
<script type="text/javascript" src="../../js/highlight.min.js"></script>
|
||||
<script type="text/javascript" src="../../js/highlightjs-line-numbers.min.js"></script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div class="content">
|
||||
<div class="breadCrumbs">
|
||||
Current scope: <a href="../../index.html">all classes</a>
|
||||
<span class="separator">|</span>
|
||||
<a href="../index.html">it.polimi.ingsw.gc14.Network.RMI.Common</a>
|
||||
</div>
|
||||
|
||||
<h1>Coverage Summary for Class: IGameServer (it.polimi.ingsw.gc14.Network.RMI.Common)</h1>
|
||||
|
||||
<table class="coverageStats">
|
||||
<tr>
|
||||
<th class="name">Class</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name">IGameServer</td>
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
|
||||
<br/>
|
||||
<br/>
|
||||
|
||||
|
||||
<pre>
|
||||
<code class="sourceCode" id="sourceCode"> package it.polimi.ingsw.gc14.Network.RMI.Common;
|
||||
|
||||
import it.polimi.ingsw.gc14.ErrorType;
|
||||
|
||||
import java.rmi.*;
|
||||
|
||||
/**
|
||||
* Remote interface used by RMI clients to interact with the game server.
|
||||
*/
|
||||
public interface IGameServer extends Remote {
|
||||
|
||||
/**
|
||||
* Adds a player to the game and registers the callback used by the server
|
||||
* to notify the corresponding RMI client.
|
||||
*
|
||||
* @param username the username chosen by the player.
|
||||
* @param preferredInt the desired number of players proposed by this client.
|
||||
* @param callback the remote callback associated with the client.
|
||||
* @return {@code null} if the player joins successfully;
|
||||
* an {@link it.polimi.ingsw.gc14.ErrorType} value describing the rejection otherwise.
|
||||
* @throws RemoteException if an RMI communication error occurs.
|
||||
*/
|
||||
ErrorType joinGame(String username, int preferredInt, IClientCallback callback) throws RemoteException;
|
||||
|
||||
/**
|
||||
* Requests to draw a tribe card from the upper tribe card list.
|
||||
*
|
||||
* @param playerUsername the username of the player performing the action.
|
||||
* @param pos the position of the selected card.
|
||||
* @throws RemoteException if an RMI communication error occurs.
|
||||
*/
|
||||
void drawUpperTribeCard(String playerUsername, int pos) throws RemoteException;
|
||||
|
||||
/**
|
||||
* Requests to draw a tribe card from the lower tribe card list.
|
||||
*
|
||||
* @param playerUsername the username of the player performing the action.
|
||||
* @param pos the position of the selected card.
|
||||
* @throws RemoteException if an RMI communication error occurs.
|
||||
*/
|
||||
void drawLowerTribeCard(String playerUsername, int pos) throws RemoteException;
|
||||
|
||||
/**
|
||||
* Requests to draw a building card from the upper building card list.
|
||||
*
|
||||
* @param playerUsername the username of the player performing the action.
|
||||
* @param pos the position of the selected card.
|
||||
* @throws RemoteException if an RMI communication error occurs.
|
||||
*/
|
||||
void drawUpperBuildingCard(String playerUsername, int pos) throws RemoteException;
|
||||
|
||||
/**
|
||||
* Requests to draw a building card from the lower building card list.
|
||||
*
|
||||
* @param playerUsername the username of the player performing the action.
|
||||
* @param pos the position of the selected card.
|
||||
* @throws RemoteException if an RMI communication error occurs.
|
||||
*/
|
||||
void drawLowerBuildingCard(String playerUsername, int pos) throws RemoteException;
|
||||
|
||||
/**
|
||||
* Requests to skip the current player's optional action.
|
||||
*
|
||||
* @param playerUsername the username of the player skipping the action.
|
||||
* @throws RemoteException if an RMI communication error occurs.
|
||||
*/
|
||||
void skipTurn(String playerUsername) throws RemoteException;
|
||||
|
||||
/**
|
||||
* Requests to assign the specified player to a slot.
|
||||
*
|
||||
* @param playerUsername the username of the player making the slot choice.
|
||||
* @param pos the position of the selected slot.
|
||||
* @throws RemoteException if an RMI communication error occurs.
|
||||
*/
|
||||
void slotChoice(String playerUsername, int pos) throws RemoteException;
|
||||
|
||||
/**
|
||||
* Requests to assign the selected totem to the specified player.
|
||||
*
|
||||
* @param playerUsername the username of the player making the totem choice.
|
||||
* @param totems the name of the selected totem.
|
||||
* @throws RemoteException if an RMI communication error occurs.
|
||||
*/
|
||||
void totemChoice(String playerUsername, String totems) throws RemoteException;
|
||||
|
||||
/**
|
||||
* Heartbeat method called periodically by the client to signal
|
||||
* that it is still connected.
|
||||
*
|
||||
* <p>This method mirrors the PING/PONG mechanism used in the TCP
|
||||
* heartbeat channel.
|
||||
*
|
||||
* @param username the username of the client sending the heartbeat ping.
|
||||
* @throws RemoteException if an RMI communication error occurs.
|
||||
*/
|
||||
void ping(String username) throws RemoteException;
|
||||
|
||||
/**
|
||||
* Notifies the server of a voluntary disconnection for the specified player.
|
||||
*
|
||||
* @param username the username of the player disconnecting.
|
||||
* @throws RemoteException if an RMI communication error occurs.
|
||||
*/
|
||||
void disconnectPlayer(String username) throws RemoteException;
|
||||
}
|
||||
</code>
|
||||
</pre>
|
||||
</div>
|
||||
|
||||
<script type="text/javascript">
|
||||
(function() {
|
||||
var msie = false, msie9 = false;
|
||||
/*@cc_on
|
||||
msie = true;
|
||||
@if (@_jscript_version >= 9)
|
||||
msie9 = true;
|
||||
@end
|
||||
@*/
|
||||
|
||||
if (!msie || msie && msie9) {
|
||||
hljs.highlightAll()
|
||||
hljs.initLineNumbersOnLoad();
|
||||
}
|
||||
})();
|
||||
</script>
|
||||
|
||||
<div class="footer">
|
||||
|
||||
<div style="float:right;">generated on 2026-06-14 21:53</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user