Package com.google.apphosting.api
Class ApiStats
java.lang.Object
com.google.apphosting.api.ApiStats
Represents automatic statistics collected by the ApiProxy. If present, this
object will be stored under the KEY-variable in an Environment's property.
This object is basically a pojo, a simple container for collected values.
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCreates a new ApiStats object and binds it to a given Environment. -
Method Summary
Modifier and TypeMethodDescriptionstatic ApiStatsget(ApiProxy.Environment env) For a given environment, return the corresponding ApiStats object.abstract longabstract long
-
Constructor Details
-
ApiStats
Creates a new ApiStats object and binds it to a given Environment.- Parameters:
env- the Environment object to bind this object to.- Throws:
IllegalStateException- if an object is already bound
-
-
Method Details
-
get
For a given environment, return the corresponding ApiStats object. If the environment does not have an ApiStats object, null will be returned. -
getApiTimeInMegaCycles
public abstract long getApiTimeInMegaCycles()- Returns:
- the overall time spent in API cycles, as returned by the system. Unit is megacycles.
-
getCpuTimeInMegaCycles
public abstract long getCpuTimeInMegaCycles()- Returns:
- the overall time spent in CPU processing. Unit is megacycles.
-