Add a getter for the active tag
Change-Id: I597e041867fba7efae41feea63fa196bc10e4aa2
This commit is contained in:
committed by
Jeff Sharkey
parent
861849e10e
commit
2c295f0c6d
@@ -96,6 +96,15 @@ public class TrafficStats {
|
||||
NetworkManagementSocketTagger.setThreadSocketStatsTag(tag);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the active tag used when accounting {@link Socket} traffic originating
|
||||
* from the current thread. Only one active tag per thread is supported.
|
||||
* {@link #tagSocket(Socket)}.
|
||||
*/
|
||||
public static int getThreadStatsTag() {
|
||||
return NetworkManagementSocketTagger.getThreadSocketStatsTag();
|
||||
}
|
||||
|
||||
/**
|
||||
* @deprecated unsupported, will eventually be removed
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user