User Tools

Site Tools


pads:gaia-apis

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
pads:gaia-apis [2010/11/10 13:15] gdangelopads:gaia-apis [2010/11/10 13:36] gdangelo
Line 56: Line 56:
 Returns the LP identifier. Returns the LP identifier.
  
 +----
  
 ===  GAIA_Finalize()  === ===  GAIA_Finalize()  ===
Line 77: Line 78:
  
 //none// //none//
 +
 +----
  
  
Line 94: Line 97:
  
 //none// //none//
 +
 +----
  
  
Line 99: Line 104:
  
 //none// //none//
 +
 +----
  
  
Line 121: Line 128:
  
 The time-step length (double). The time-step length (double).
 +
 +----
  
  
Line 143: Line 152:
  
 The descriptor (integer) of the SE. The descriptor (integer) of the SE.
 +
 +----
  
  
Line 165: Line 176:
  
 Returns the next timestep value (double). Returns the next timestep value (double).
 +
 +----
 +
  
  
 ==== Migration ==== ==== Migration ====
 +
 +
 +===  GAIA_Migrate()  ===
 +<code java>
 +void    GAIA_Migrate (int id, String data, int size);
 +</code>
 +
 +**Parameters**:
 +   * int **id**: Identifier of the migrating SE;
 +   * String **data**: A string containing the internal state of the SE;
 +   * int **size**: String size;
 +
 +
 +**Description**:
 +
 +It is used by a local LP to migrate a SE to a remote LP. The local LP is **not** free to define what SEs should be migrated. During the simulation execution, the migration mechanism defines what SEs have to be migrated and informs the LP using a "NOTIF_MIGR" message. The other LPs that are not directly involved in the migration will be informed of the event with a "NOTIF_MIGR_EXT".
 +
 +**Notes**:
 +
 +   * The "NOTIF_MIGR" message and the related migration are **mandatory**. The LPs cannot independently migrate any SE without previously receiving a "NOTIF_MIGR" message. This migration of "notified" SEs have to be done at the end of the timestep in which is received the notification.
 +
 +   * The GAIA_Migrate() is implemented using a "EXEC_MIGR" message. Therefore, the LP that receives a message of this type is receiving a migrating Simulated Entity.
 +
 +**Return value:**
 +
 +//none//
 +
 +----
 +
 +
 +===  GAIA_ByteMigrate()  ===
 +<code java>
 +void    GAIA_ByteMigrate (int id, byte[] data, int size);
 +</code>
 +
 +**Parameters**:
 +   * int **id**: Identifier of the migrating SE;
 +   * byte[] **data**: A byte-array containing the internal state of the SE;
 +   * int **size**: String size;
 +
 +
 +**Description**:
 +
 +It is used by a local LP to migrate a SE to a remote LP. The local LP is **not** free to define what SEs should be migrated. During the simulation execution, the migration mechanism defines what SEs have to be migrated and informs the  LP using a "NOTIF_MIGR" message. The other LPs that are not directly involved in the migration will be informed of the event with a “NOTIF_MIGR_EXT”. 
 +
 +**Notes**:
 +
 +   * The "NOTIF_MIGR" message and the related migration are **mandatory**. The LPs cannot independently migrate any SE without previously receiving a "NOTIF_MIGR" message. This migration of “notified” SEs have to be done at the end of the timestep in which is received the notification. 
 +
 +   * The GAIA_ByteMigrate() is implemented using a “EXEC_MIGR” message. Therefore, the LP that receives a message of this type is receiving a migrating Simulated Entity.
 +
 +   * This API has the exactly the same semantic of GAIA_Migrate(). For performance reasons, in this case the SE state is contained in an array instead of a String.
 +
 +**Return value:**
 +
 +//none//
 +
 +----
 +
  
 ===  GAIA_SetCountDown()  === ===  GAIA_SetCountDown()  ===
Line 189: Line 262:
  
 //none// //none//
 +
 +----
  
  
Line 219: Line 294:
  
 //none// //none//
 +
 +----
  
  
Line 240: Line 317:
  
 //none// //none//
 +
 +----
  
  
Line 261: Line 340:
  
 //none// //none//
 +
 +----
  
  
Line 282: Line 363:
  
 //none// //none//
 +
 +----
 +
  
 ===  GAIA_SetMigration()  === ===  GAIA_SetMigration()  ===
Line 316: Line 400:
  
 //none// //none//
 +
 +----
 +
  
 ==== Load Balancing ==== ==== Load Balancing ====
Line 339: Line 426:
 //none// //none//
  
 +----
  
-====  GAIA_Migrate()  ==== 
-<code java> 
-void    GAIA_Migrate (int id, String data, int size); 
-</code> 
- 
-**Parameters**: 
-   * int **id**: Identifier of the migrating SE; 
-   * String **data**: A string containing the internal state of the SE; 
-   * int **size**: String size; 
- 
- 
-**Description**: 
- 
-It is used by a local LP to migrate a SE to a remote LP. The local LP is **not** free to define what SEs should be migrated. During the simulation execution, the migration mechanism defines what SEs have to be migrated and informs the LP using a "NOTIF_MIGR" message. The other LPs that are not directly involved in the migration will be informed of the event with a "NOTIF_MIGR_EXT". 
- 
-**Notes**: 
- 
-   * The "NOTIF_MIGR" message and the related migration are **mandatory**. The LPs cannot independently migrate any SE without previously receiving a "NOTIF_MIGR" message. This migration of "notified" SEs have to be done at the end of the timestep in which is received the notification. 
- 
-   * The GAIA_Migrate() is implemented using a "EXEC_MIGR" message. Therefore, the LP that receives a message of this type is receiving a migrating Simulated Entity. 
- 
-**Return value:** 
- 
-//none// 
- 
- 
-====  GAIA_ByteMigrate()  ==== 
-<code java> 
-void    GAIA_ByteMigrate (int id, byte[] data, int size); 
-</code> 
- 
-**Parameters**: 
-   * int **id**: Identifier of the migrating SE; 
-   * byte[] **data**: A byte-array containing the internal state of the SE; 
-   * int **size**: String size; 
- 
- 
-**Description**: 
- 
-It is used by a local LP to migrate a SE to a remote LP. The local LP is **not** free to define what SEs should be migrated. During the simulation execution, the migration mechanism defines what SEs have to be migrated and informs the  LP using a "NOTIF_MIGR" message. The other LPs that are not directly involved in the migration will be informed of the event with a “NOTIF_MIGR_EXT”.  
- 
-**Notes**: 
- 
-   * The "NOTIF_MIGR" message and the related migration are **mandatory**. The LPs cannot independently migrate any SE without previously receiving a "NOTIF_MIGR" message. This migration of “notified” SEs have to be done at the end of the timestep in which is received the notification.  
- 
-   * The GAIA_ByteMigrate() is implemented using a “EXEC_MIGR” message. Therefore, the LP that receives a message of this type is receiving a migrating Simulated Entity. 
- 
-   * This API has the exactly the same semantic of GAIA_Migrate(). For performance reasons, in this case the SE state is contained in an array instead of a String. 
- 
-**Return value:** 
- 
-//none// 
  
 +====  Communication  ====
  
-====  GAIA_Send()  ====+===  GAIA_Send()  ===
 <code java> <code java>
 void    GAIA_Send (int obj_src, int obj_dest, double Ts, String Msg, int Size); void    GAIA_Send (int obj_src, int obj_dest, double Ts, String Msg, int Size);
Line 419: Line 456:
 //none// //none//
  
 +----
  
-====  GAIA_ByteSend()  ====+ 
 +===  GAIA_ByteSend()  ===
 <code java> <code java>
 void    GAIA_ByteSend (int obj_src, int obj_dest, double Ts, byte[] Msg, int Size); void    GAIA_ByteSend (int obj_src, int obj_dest, double Ts, byte[] Msg, int Size);
Line 447: Line 486:
  
 //none// //none//
 +
 +----
  
  
-====  GAIA_Broadcast()  ====+===  GAIA_Broadcast()  ===
 <code java> <code java>
 void    GAIA_Broadcast (int obj_src, double Ts, String Msg, int Size); void    GAIA_Broadcast (int obj_src, double Ts, String Msg, int Size);
Line 475: Line 516:
 //none// //none//
  
 +----
  
-====  GAIA_ByteBroadcast()  ====+ 
 +===  GAIA_ByteBroadcast()  ===
 <code java> <code java>
 void    GAIA_ByteBroadcast (int obj_src, double Ts, byte[] Msg, int Size); void    GAIA_ByteBroadcast (int obj_src, double Ts, byte[] Msg, int Size);
Line 504: Line 547:
  
 //none// //none//
 +
 +----
  
  
-====  GAIA_Receive()  ====+===  GAIA_Receive()  ===
 <code java> <code java>
 String  GAIA_Receive(int maxlen); String  GAIA_Receive(int maxlen);
Line 533: Line 578:
 Returns the message (String). Returns the message (String).
  
 +----
  
  
-====  GAIA_ByteReceive()  ====+===  GAIA_ByteReceive()  ===
 <code java> <code java>
 byte[]  GAIA_ByteReceive(int maxlen); byte[]  GAIA_ByteReceive(int maxlen);
Line 564: Line 610:
 Returns the message (byte-array). Returns the message (byte-array).
  
-====  GAIA_GetStatistics()  ====+---- 
 + 
 + 
 +==== Statistics ==== 
 + 
 + 
 +===  GAIA_GetStatistics()  ===
 <code java> <code java>
 void  GAIA_GetStatistics(); void  GAIA_GetStatistics();
Line 589: Line 641:
  
 //none// //none//
 +
 +
 +----
  
 ===== C bindings ===== ===== C bindings =====
pads/gaia-apis.txt · Last modified: 2017/12/20 07:48 by gdangelo

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki