Interface ComponentStatisticsProvider
-
public interface ComponentStatisticsProvider
A provider of statistics data about some resources managed in a given Silverpeas Component. Each statistics provider must be managed in CDI and retrieved by a name that qualifies them (annotation @Named). This name must satisfy the following rule: the name of the component that provides this statistics provider suffixed by the value of theQUALIFIER_SUFFIX
constant.
-
-
Field Summary
Fields Modifier and Type Field Description static String
QUALIFIER_SUFFIX
The suffix of the name for each statistics provider.
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default long
countSpecificFiles(String componentId)
Counts the number of document the application instance uses by taking into account only the specific files handled by the application.static Optional<ComponentStatisticsProvider>
getByComponentName(String componentName)
Collection<UserIdCountVolumeCouple>
getVolume(String spaceId, String componentId)
Gets by user the number of owned contributions.default long
memorySizeOfSpecificFiles(String componentId)
Gets the memory size of documents of the application instance by taking into account only the specific files handled by the application.
-
-
-
Field Detail
-
QUALIFIER_SUFFIX
static final String QUALIFIER_SUFFIX
The suffix of the name for each statistics provider.- See Also:
- Constant Field Values
-
-
Method Detail
-
getByComponentName
static Optional<ComponentStatisticsProvider> getByComponentName(String componentName)
-
getVolume
Collection<UserIdCountVolumeCouple> getVolume(String spaceId, String componentId) throws org.silverpeas.kernel.SilverpeasException
Gets by user the number of owned contributions.- Parameters:
spaceId
- the identifier of space which the component represented by componentId parameter is linked to.componentId
- the identifier of the current looked component instance.- Returns:
- a collection of
UserIdCountVolumeCouple
. The collection can contains severalUserIdCountVolumeCouple
with the same user identifier. - Throws:
org.silverpeas.kernel.SilverpeasException
- on technical error.
-
memorySizeOfSpecificFiles
default long memorySizeOfSpecificFiles(String componentId)
Gets the memory size of documents of the application instance by taking into account only the specific files handled by the application.The files handled by transverse services are taken into account by other statistic services.
- Parameters:
componentId
- the identifier of the current looked component instance.- Returns:
- a long.
-
countSpecificFiles
default long countSpecificFiles(String componentId)
Counts the number of document the application instance uses by taking into account only the specific files handled by the application.The files handled by transverse services are taken into account by other statistic services.
- Parameters:
componentId
- the identifier of the current looked component instance.- Returns:
- a long.
-
-