Class PendingUsageActivity
java.lang.Object
org.odpi.openmetadata.adapters.connectors.pepys.PendingUsageActivity
PendingUsageActivity accumulates the activity observed for a single element since its UsageActivity
classification was last written. There is one count for each kind of activity, and the counts are added to the
classification's values on the next refresh.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidadd(PendingUsageActivity other) Add the counts from another set of pending activity.longgetCount(ObservedActivity.UsageCount usageCount) Return the number of activities of a particular kind that have been observed.longgetTotal()Return the total number of activities observed.voidincrement(ObservedActivity.UsageCount usageCount) Increment the count for an activity.toString()JSON-style toString
-
Constructor Details
-
PendingUsageActivity
public PendingUsageActivity()Default constructor
-
-
Method Details
-
increment
Increment the count for an activity.- Parameters:
usageCount- count to increment
-
add
Add the counts from another set of pending activity. This is used to put back the counts that could not be written so that they are tried again on the next refresh.- Parameters:
other- counts to add
-
getCount
Return the number of activities of a particular kind that have been observed.- Parameters:
usageCount- kind of activity- Returns:
- long
-
getTotal
public long getTotal()Return the total number of activities observed.- Returns:
- long
-
toString
JSON-style toString
-