Package io.opencensus.trace.export
Class RunningSpanStore.Filter
- java.lang.Object
-
- io.opencensus.trace.export.RunningSpanStore.Filter
-
- Direct Known Subclasses:
AutoValue_RunningSpanStore_Filter
- Enclosing class:
- RunningSpanStore
@Immutable public abstract static class RunningSpanStore.Filter extends java.lang.Object
Filter for running spans. Used to filter results returned by theRunningSpanStore.getRunningSpans(Filter)
request.- Since:
- 0.5
-
-
Constructor Summary
Constructors Constructor Description Filter()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description static RunningSpanStore.Filter
create(java.lang.String spanName, int maxSpansToReturn)
Returns a new instance ofFilter
.abstract int
getMaxSpansToReturn()
Returns the maximum number of spans to be returned.abstract java.lang.String
getSpanName()
Returns the span name.
-
-
-
Method Detail
-
create
public static RunningSpanStore.Filter create(java.lang.String spanName, int maxSpansToReturn)
Returns a new instance ofFilter
.Filters all the spans based on
spanName
and returns a maximum ofmaxSpansToReturn
.- Parameters:
spanName
- the name of the span.maxSpansToReturn
- the maximum number of results to be returned.0
means all.- Returns:
- a new instance of
Filter
. - Throws:
java.lang.NullPointerException
- ifspanName
isnull
.java.lang.IllegalArgumentException
- ifmaxSpansToReturn
is negative.- Since:
- 0.5
-
getSpanName
public abstract java.lang.String getSpanName()
Returns the span name.- Returns:
- the span name.
- Since:
- 0.5
-
getMaxSpansToReturn
public abstract int getMaxSpansToReturn()
Returns the maximum number of spans to be returned.0
means all.- Returns:
- the maximum number of spans to be returned.
- Since:
- 0.5
-
-