Package jline.api.sn

Class SnSetServersKt

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Constructor Detail

    • Method Detail

      • snSetServers

         final static NetworkStruct snSetServers(NetworkStruct sn, Integer stationIdx, Double nServers, ModifyMode mode, ValidationLevel validation)

        Sets the number of servers at a station.

        Updates the nservers matrix in the NetworkStruct.

        Parameters:
        sn - NetworkStruct to modify
        stationIdx - Station index (0-based)
        nServers - Number of servers (positive, or Double.
        mode - IN_PLACE modifies sn directly, COPY returns a modified copy
        validation - Validation level to apply
        Returns:

        Modified NetworkStruct

      • snSetServersBatch

         final static NetworkStruct snSetServersBatch(NetworkStruct sn, Matrix nServers, ModifyMode mode, ValidationLevel validation)

        Sets the number of servers for multiple stations in a single operation.

        More efficient than calling snSetServers multiple times. NaN values in the nServers matrix are skipped (not updated).

        Parameters:
        sn - NetworkStruct to modify
        nServers - Matrix of new server counts (nstations x 1) - NaN values are skipped
        mode - IN_PLACE modifies sn directly, COPY returns a modified copy
        validation - Validation level to apply
        Returns:

        Modified NetworkStruct