Class ProtonLinkCreditState
java.lang.Object
org.apache.qpid.protonj2.engine.impl.ProtonLinkCreditState
- All Implemented Interfaces:
LinkCreditState
Holds the current credit state for a given link.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintThe currently available credit for this linkintThe current delivery count value for this linkbooleanisDrain()booleanisEcho()voidupdateCredit(int effectiveCredit) voidupdateDeliveryCount(int deliveryCount)
-
Constructor Details
-
ProtonLinkCreditState
public ProtonLinkCreditState() -
ProtonLinkCreditState
public ProtonLinkCreditState(int deliveryCount)
-
-
Method Details
-
getCredit
public int getCredit()Description copied from interface:LinkCreditStateThe currently available credit for this link- Specified by:
getCreditin interfaceLinkCreditState- Returns:
- the current amount of link credit
-
getDeliveryCount
public int getDeliveryCount()Description copied from interface:LinkCreditStateThe current delivery count value for this link- Specified by:
getDeliveryCountin interfaceLinkCreditState- Returns:
- the current delivery count value for the link.
-
isDrain
public boolean isDrain()- Specified by:
isDrainin interfaceLinkCreditState- Returns:
- true if the link drain is active.
-
isEcho
public boolean isEcho()- Specified by:
isEchoin interfaceLinkCreditState- Returns:
- true if the link has been requested to echo its state.
-
updateCredit
public void updateCredit(int effectiveCredit) -
updateDeliveryCount
public void updateDeliveryCount(int deliveryCount)
-