Package jline.lang.constant
Enum ImpatienceType
- All Implemented Interfaces:
Serializable,Comparable<ImpatienceType>,java.lang.constant.Constable
Constants for specifying customer impatience types.
Impatience refers to customers leaving a queueing system without receiving service.
The main types are:
- RENEGING: Customer abandons after joining the queue (timer-based abandonment)
- BALKING: Customer refuses to join based on queue state (queue-length or wait-time based)
- RETRIAL: Customer moves to orbit and retries entry after a delay
ID values match MATLAB ImpatienceType constants.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum Constants -
Method Summary
Modifier and TypeMethodDescriptionstatic ImpatienceTypefromID(int id) Convert numeric ID to ImpatienceType enum value.intgetID()Get the numeric ID for this impatience type.static StringtoText(ImpatienceType type) Convert ImpatienceType to human-readable text.static ImpatienceTypeReturns the enum constant of this type with the specified name.static ImpatienceType[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
RENEGING
Reneging - customer abandons the queue after waiting too long. This is the standard "impatience" where a job joins the queue but leaves before service if its patience time expires. Currently supported by JMT solver. -
BALKING
Balking - customer refuses to join the queue based on queue state. This occurs when a customer arrives but decides not to join based on factors like queue length or expected waiting time. -
RETRIAL
Retrial - customer moves to orbit and retries queue entry after a delay. This occurs when a customer is rejected due to capacity constraints and enters an "orbit" buffer, periodically attempting to re-enter. Supports both unlimited retries and configurable maximum attempts.
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
getID
public int getID()Get the numeric ID for this impatience type. IDs match MATLAB ImpatienceType constants.- Returns:
- numeric ID
-
fromID
Convert numeric ID to ImpatienceType enum value.- Parameters:
id- numeric impatience type ID- Returns:
- corresponding ImpatienceType enum value
- Throws:
IllegalArgumentException- if ID is not recognized
-
toText
Convert ImpatienceType to human-readable text.- Parameters:
type- the impatience type- Returns:
- text description
-