| Motomu Utsumi | 5dcd145 | 2023-09-07 18:39:06 +0900 | [diff] [blame] | 1 | // Signature format: 2.0 | 
 | 2 | package android.app.usage { | 
 | 3 |  | 
 | 4 |   public final class NetworkStats implements java.lang.AutoCloseable { | 
 | 5 |     method public void close(); | 
 | 6 |     method public boolean getNextBucket(@Nullable android.app.usage.NetworkStats.Bucket); | 
 | 7 |     method public boolean hasNextBucket(); | 
 | 8 |   } | 
 | 9 |  | 
 | 10 |   public static class NetworkStats.Bucket { | 
 | 11 |     ctor public NetworkStats.Bucket(); | 
 | 12 |     method public int getDefaultNetworkStatus(); | 
 | 13 |     method public long getEndTimeStamp(); | 
 | 14 |     method public int getMetered(); | 
 | 15 |     method public int getRoaming(); | 
 | 16 |     method public long getRxBytes(); | 
 | 17 |     method public long getRxPackets(); | 
 | 18 |     method public long getStartTimeStamp(); | 
 | 19 |     method public int getState(); | 
 | 20 |     method public int getTag(); | 
 | 21 |     method public long getTxBytes(); | 
 | 22 |     method public long getTxPackets(); | 
 | 23 |     method public int getUid(); | 
 | 24 |     field public static final int DEFAULT_NETWORK_ALL = -1; // 0xffffffff | 
 | 25 |     field public static final int DEFAULT_NETWORK_NO = 1; // 0x1 | 
 | 26 |     field public static final int DEFAULT_NETWORK_YES = 2; // 0x2 | 
 | 27 |     field public static final int METERED_ALL = -1; // 0xffffffff | 
 | 28 |     field public static final int METERED_NO = 1; // 0x1 | 
 | 29 |     field public static final int METERED_YES = 2; // 0x2 | 
 | 30 |     field public static final int ROAMING_ALL = -1; // 0xffffffff | 
 | 31 |     field public static final int ROAMING_NO = 1; // 0x1 | 
 | 32 |     field public static final int ROAMING_YES = 2; // 0x2 | 
 | 33 |     field public static final int STATE_ALL = -1; // 0xffffffff | 
 | 34 |     field public static final int STATE_DEFAULT = 1; // 0x1 | 
 | 35 |     field public static final int STATE_FOREGROUND = 2; // 0x2 | 
 | 36 |     field public static final int TAG_NONE = 0; // 0x0 | 
 | 37 |     field public static final int UID_ALL = -1; // 0xffffffff | 
 | 38 |     field public static final int UID_REMOVED = -4; // 0xfffffffc | 
 | 39 |     field public static final int UID_TETHERING = -5; // 0xfffffffb | 
 | 40 |   } | 
 | 41 |  | 
 | 42 |   public class NetworkStatsManager { | 
 | 43 |     method @WorkerThread public android.app.usage.NetworkStats queryDetails(int, @Nullable String, long, long) throws android.os.RemoteException, java.lang.SecurityException; | 
 | 44 |     method @NonNull @WorkerThread public android.app.usage.NetworkStats queryDetailsForUid(int, @Nullable String, long, long, int) throws java.lang.SecurityException; | 
 | 45 |     method @NonNull @WorkerThread public android.app.usage.NetworkStats queryDetailsForUidTag(int, @Nullable String, long, long, int, int) throws java.lang.SecurityException; | 
 | 46 |     method @NonNull @WorkerThread public android.app.usage.NetworkStats queryDetailsForUidTagState(int, @Nullable String, long, long, int, int, int) throws java.lang.SecurityException; | 
 | 47 |     method @WorkerThread public android.app.usage.NetworkStats querySummary(int, @Nullable String, long, long) throws android.os.RemoteException, java.lang.SecurityException; | 
 | 48 |     method @WorkerThread public android.app.usage.NetworkStats.Bucket querySummaryForDevice(int, @Nullable String, long, long) throws android.os.RemoteException, java.lang.SecurityException; | 
 | 49 |     method @WorkerThread public android.app.usage.NetworkStats.Bucket querySummaryForUser(int, @Nullable String, long, long) throws android.os.RemoteException, java.lang.SecurityException; | 
 | 50 |     method public void registerUsageCallback(int, @Nullable String, long, @NonNull android.app.usage.NetworkStatsManager.UsageCallback); | 
 | 51 |     method public void registerUsageCallback(int, @Nullable String, long, @NonNull android.app.usage.NetworkStatsManager.UsageCallback, @Nullable android.os.Handler); | 
 | 52 |     method public void unregisterUsageCallback(@NonNull android.app.usage.NetworkStatsManager.UsageCallback); | 
 | 53 |   } | 
 | 54 |  | 
 | 55 |   public abstract static class NetworkStatsManager.UsageCallback { | 
 | 56 |     ctor public NetworkStatsManager.UsageCallback(); | 
 | 57 |     method public abstract void onThresholdReached(int, @Nullable String); | 
 | 58 |   } | 
 | 59 |  | 
 | 60 | } | 
 | 61 |  | 
 | 62 | package android.net { | 
 | 63 |  | 
 | 64 |   public final class EthernetNetworkSpecifier extends android.net.NetworkSpecifier implements android.os.Parcelable { | 
 | 65 |     ctor public EthernetNetworkSpecifier(@NonNull String); | 
 | 66 |     method public int describeContents(); | 
 | 67 |     method @Nullable public String getInterfaceName(); | 
 | 68 |     method public void writeToParcel(@NonNull android.os.Parcel, int); | 
 | 69 |     field @NonNull public static final android.os.Parcelable.Creator<android.net.EthernetNetworkSpecifier> CREATOR; | 
 | 70 |   } | 
 | 71 |  | 
 | 72 |   public final class IpSecAlgorithm implements android.os.Parcelable { | 
 | 73 |     ctor public IpSecAlgorithm(@NonNull String, @NonNull byte[]); | 
 | 74 |     ctor public IpSecAlgorithm(@NonNull String, @NonNull byte[], int); | 
 | 75 |     method public int describeContents(); | 
 | 76 |     method @NonNull public byte[] getKey(); | 
 | 77 |     method @NonNull public String getName(); | 
 | 78 |     method @NonNull public static java.util.Set<java.lang.String> getSupportedAlgorithms(); | 
 | 79 |     method public int getTruncationLengthBits(); | 
 | 80 |     method public void writeToParcel(android.os.Parcel, int); | 
 | 81 |     field public static final String AUTH_AES_CMAC = "cmac(aes)"; | 
 | 82 |     field public static final String AUTH_AES_XCBC = "xcbc(aes)"; | 
 | 83 |     field public static final String AUTH_CRYPT_AES_GCM = "rfc4106(gcm(aes))"; | 
 | 84 |     field public static final String AUTH_CRYPT_CHACHA20_POLY1305 = "rfc7539esp(chacha20,poly1305)"; | 
 | 85 |     field public static final String AUTH_HMAC_MD5 = "hmac(md5)"; | 
 | 86 |     field public static final String AUTH_HMAC_SHA1 = "hmac(sha1)"; | 
 | 87 |     field public static final String AUTH_HMAC_SHA256 = "hmac(sha256)"; | 
 | 88 |     field public static final String AUTH_HMAC_SHA384 = "hmac(sha384)"; | 
 | 89 |     field public static final String AUTH_HMAC_SHA512 = "hmac(sha512)"; | 
 | 90 |     field @NonNull public static final android.os.Parcelable.Creator<android.net.IpSecAlgorithm> CREATOR; | 
 | 91 |     field public static final String CRYPT_AES_CBC = "cbc(aes)"; | 
 | 92 |     field public static final String CRYPT_AES_CTR = "rfc3686(ctr(aes))"; | 
 | 93 |   } | 
 | 94 |  | 
 | 95 |   public class IpSecManager { | 
 | 96 |     method @NonNull public android.net.IpSecManager.SecurityParameterIndex allocateSecurityParameterIndex(@NonNull java.net.InetAddress) throws android.net.IpSecManager.ResourceUnavailableException; | 
 | 97 |     method @NonNull public android.net.IpSecManager.SecurityParameterIndex allocateSecurityParameterIndex(@NonNull java.net.InetAddress, int) throws android.net.IpSecManager.ResourceUnavailableException, android.net.IpSecManager.SpiUnavailableException; | 
 | 98 |     method public void applyTransportModeTransform(@NonNull java.net.Socket, int, @NonNull android.net.IpSecTransform) throws java.io.IOException; | 
 | 99 |     method public void applyTransportModeTransform(@NonNull java.net.DatagramSocket, int, @NonNull android.net.IpSecTransform) throws java.io.IOException; | 
 | 100 |     method public void applyTransportModeTransform(@NonNull java.io.FileDescriptor, int, @NonNull android.net.IpSecTransform) throws java.io.IOException; | 
 | 101 |     method @NonNull public android.net.IpSecManager.UdpEncapsulationSocket openUdpEncapsulationSocket(int) throws java.io.IOException, android.net.IpSecManager.ResourceUnavailableException; | 
 | 102 |     method @NonNull public android.net.IpSecManager.UdpEncapsulationSocket openUdpEncapsulationSocket() throws java.io.IOException, android.net.IpSecManager.ResourceUnavailableException; | 
 | 103 |     method public void removeTransportModeTransforms(@NonNull java.net.Socket) throws java.io.IOException; | 
 | 104 |     method public void removeTransportModeTransforms(@NonNull java.net.DatagramSocket) throws java.io.IOException; | 
 | 105 |     method public void removeTransportModeTransforms(@NonNull java.io.FileDescriptor) throws java.io.IOException; | 
 | 106 |     field public static final int DIRECTION_IN = 0; // 0x0 | 
 | 107 |     field public static final int DIRECTION_OUT = 1; // 0x1 | 
 | 108 |   } | 
 | 109 |  | 
 | 110 |   public static final class IpSecManager.ResourceUnavailableException extends android.util.AndroidException { | 
 | 111 |   } | 
 | 112 |  | 
 | 113 |   public static final class IpSecManager.SecurityParameterIndex implements java.lang.AutoCloseable { | 
 | 114 |     method public void close(); | 
 | 115 |     method public int getSpi(); | 
 | 116 |   } | 
 | 117 |  | 
 | 118 |   public static final class IpSecManager.SpiUnavailableException extends android.util.AndroidException { | 
 | 119 |     method public int getSpi(); | 
 | 120 |   } | 
 | 121 |  | 
 | 122 |   public static final class IpSecManager.UdpEncapsulationSocket implements java.lang.AutoCloseable { | 
 | 123 |     method public void close() throws java.io.IOException; | 
 | 124 |     method public java.io.FileDescriptor getFileDescriptor(); | 
 | 125 |     method public int getPort(); | 
 | 126 |   } | 
 | 127 |  | 
 | 128 |   public final class IpSecTransform implements java.lang.AutoCloseable { | 
 | 129 |     method public void close(); | 
 | 130 |   } | 
 | 131 |  | 
 | 132 |   public static class IpSecTransform.Builder { | 
 | 133 |     ctor public IpSecTransform.Builder(@NonNull android.content.Context); | 
 | 134 |     method @NonNull public android.net.IpSecTransform buildTransportModeTransform(@NonNull java.net.InetAddress, @NonNull android.net.IpSecManager.SecurityParameterIndex) throws java.io.IOException, android.net.IpSecManager.ResourceUnavailableException, android.net.IpSecManager.SpiUnavailableException; | 
 | 135 |     method @NonNull public android.net.IpSecTransform.Builder setAuthenticatedEncryption(@NonNull android.net.IpSecAlgorithm); | 
 | 136 |     method @NonNull public android.net.IpSecTransform.Builder setAuthentication(@NonNull android.net.IpSecAlgorithm); | 
 | 137 |     method @NonNull public android.net.IpSecTransform.Builder setEncryption(@NonNull android.net.IpSecAlgorithm); | 
 | 138 |     method @NonNull public android.net.IpSecTransform.Builder setIpv4Encapsulation(@NonNull android.net.IpSecManager.UdpEncapsulationSocket, int); | 
 | 139 |   } | 
 | 140 |  | 
 | 141 |   public class TrafficStats { | 
 | 142 |     ctor public TrafficStats(); | 
 | 143 |     method public static void clearThreadStatsTag(); | 
 | 144 |     method public static void clearThreadStatsUid(); | 
 | 145 |     method public static int getAndSetThreadStatsTag(int); | 
 | 146 |     method public static long getMobileRxBytes(); | 
 | 147 |     method public static long getMobileRxPackets(); | 
 | 148 |     method public static long getMobileTxBytes(); | 
 | 149 |     method public static long getMobileTxPackets(); | 
 | 150 |     method public static long getRxBytes(@NonNull String); | 
 | 151 |     method public static long getRxPackets(@NonNull String); | 
 | 152 |     method public static int getThreadStatsTag(); | 
 | 153 |     method public static int getThreadStatsUid(); | 
 | 154 |     method public static long getTotalRxBytes(); | 
 | 155 |     method public static long getTotalRxPackets(); | 
 | 156 |     method public static long getTotalTxBytes(); | 
 | 157 |     method public static long getTotalTxPackets(); | 
 | 158 |     method public static long getTxBytes(@NonNull String); | 
 | 159 |     method public static long getTxPackets(@NonNull String); | 
 | 160 |     method public static long getUidRxBytes(int); | 
 | 161 |     method public static long getUidRxPackets(int); | 
 | 162 |     method @Deprecated public static long getUidTcpRxBytes(int); | 
 | 163 |     method @Deprecated public static long getUidTcpRxSegments(int); | 
 | 164 |     method @Deprecated public static long getUidTcpTxBytes(int); | 
 | 165 |     method @Deprecated public static long getUidTcpTxSegments(int); | 
 | 166 |     method public static long getUidTxBytes(int); | 
 | 167 |     method public static long getUidTxPackets(int); | 
 | 168 |     method @Deprecated public static long getUidUdpRxBytes(int); | 
 | 169 |     method @Deprecated public static long getUidUdpRxPackets(int); | 
 | 170 |     method @Deprecated public static long getUidUdpTxBytes(int); | 
 | 171 |     method @Deprecated public static long getUidUdpTxPackets(int); | 
 | 172 |     method public static void incrementOperationCount(int); | 
 | 173 |     method public static void incrementOperationCount(int, int); | 
 | 174 |     method public static void setThreadStatsTag(int); | 
 | 175 |     method public static void setThreadStatsUid(int); | 
 | 176 |     method public static void tagDatagramSocket(@NonNull java.net.DatagramSocket) throws java.net.SocketException; | 
 | 177 |     method public static void tagFileDescriptor(@NonNull java.io.FileDescriptor) throws java.io.IOException; | 
 | 178 |     method public static void tagSocket(@NonNull java.net.Socket) throws java.net.SocketException; | 
 | 179 |     method public static void untagDatagramSocket(@NonNull java.net.DatagramSocket) throws java.net.SocketException; | 
 | 180 |     method public static void untagFileDescriptor(@NonNull java.io.FileDescriptor) throws java.io.IOException; | 
 | 181 |     method public static void untagSocket(@NonNull java.net.Socket) throws java.net.SocketException; | 
 | 182 |     field public static final int UNSUPPORTED = -1; // 0xffffffff | 
 | 183 |   } | 
 | 184 |  | 
 | 185 | } | 
 | 186 |  | 
 | 187 | package android.net.nsd { | 
 | 188 |  | 
 | 189 |   public final class NsdManager { | 
 | 190 |     method public void discoverServices(String, int, android.net.nsd.NsdManager.DiscoveryListener); | 
 | 191 |     method public void discoverServices(@NonNull String, int, @Nullable android.net.Network, @NonNull java.util.concurrent.Executor, @NonNull android.net.nsd.NsdManager.DiscoveryListener); | 
 | 192 |     method @RequiresPermission(android.Manifest.permission.ACCESS_NETWORK_STATE) public void discoverServices(@NonNull String, int, @NonNull android.net.NetworkRequest, @NonNull java.util.concurrent.Executor, @NonNull android.net.nsd.NsdManager.DiscoveryListener); | 
 | 193 |     method public void registerService(android.net.nsd.NsdServiceInfo, int, android.net.nsd.NsdManager.RegistrationListener); | 
 | 194 |     method public void registerService(@NonNull android.net.nsd.NsdServiceInfo, int, @NonNull java.util.concurrent.Executor, @NonNull android.net.nsd.NsdManager.RegistrationListener); | 
 | 195 |     method public void registerServiceInfoCallback(@NonNull android.net.nsd.NsdServiceInfo, @NonNull java.util.concurrent.Executor, @NonNull android.net.nsd.NsdManager.ServiceInfoCallback); | 
 | 196 |     method @Deprecated public void resolveService(android.net.nsd.NsdServiceInfo, android.net.nsd.NsdManager.ResolveListener); | 
 | 197 |     method @Deprecated public void resolveService(@NonNull android.net.nsd.NsdServiceInfo, @NonNull java.util.concurrent.Executor, @NonNull android.net.nsd.NsdManager.ResolveListener); | 
 | 198 |     method public void stopServiceDiscovery(android.net.nsd.NsdManager.DiscoveryListener); | 
 | 199 |     method public void stopServiceResolution(@NonNull android.net.nsd.NsdManager.ResolveListener); | 
 | 200 |     method public void unregisterService(android.net.nsd.NsdManager.RegistrationListener); | 
 | 201 |     method public void unregisterServiceInfoCallback(@NonNull android.net.nsd.NsdManager.ServiceInfoCallback); | 
 | 202 |     field public static final String ACTION_NSD_STATE_CHANGED = "android.net.nsd.STATE_CHANGED"; | 
 | 203 |     field public static final String EXTRA_NSD_STATE = "nsd_state"; | 
 | 204 |     field public static final int FAILURE_ALREADY_ACTIVE = 3; // 0x3 | 
 | 205 |     field public static final int FAILURE_BAD_PARAMETERS = 6; // 0x6 | 
 | 206 |     field public static final int FAILURE_INTERNAL_ERROR = 0; // 0x0 | 
 | 207 |     field public static final int FAILURE_MAX_LIMIT = 4; // 0x4 | 
 | 208 |     field public static final int FAILURE_OPERATION_NOT_RUNNING = 5; // 0x5 | 
 | 209 |     field public static final int NSD_STATE_DISABLED = 1; // 0x1 | 
 | 210 |     field public static final int NSD_STATE_ENABLED = 2; // 0x2 | 
 | 211 |     field public static final int PROTOCOL_DNS_SD = 1; // 0x1 | 
 | 212 |   } | 
 | 213 |  | 
 | 214 |   public static interface NsdManager.DiscoveryListener { | 
 | 215 |     method public void onDiscoveryStarted(String); | 
 | 216 |     method public void onDiscoveryStopped(String); | 
 | 217 |     method public void onServiceFound(android.net.nsd.NsdServiceInfo); | 
 | 218 |     method public void onServiceLost(android.net.nsd.NsdServiceInfo); | 
 | 219 |     method public void onStartDiscoveryFailed(String, int); | 
 | 220 |     method public void onStopDiscoveryFailed(String, int); | 
 | 221 |   } | 
 | 222 |  | 
 | 223 |   public static interface NsdManager.RegistrationListener { | 
 | 224 |     method public void onRegistrationFailed(android.net.nsd.NsdServiceInfo, int); | 
 | 225 |     method public void onServiceRegistered(android.net.nsd.NsdServiceInfo); | 
 | 226 |     method public void onServiceUnregistered(android.net.nsd.NsdServiceInfo); | 
 | 227 |     method public void onUnregistrationFailed(android.net.nsd.NsdServiceInfo, int); | 
 | 228 |   } | 
 | 229 |  | 
 | 230 |   public static interface NsdManager.ResolveListener { | 
 | 231 |     method public default void onResolutionStopped(@NonNull android.net.nsd.NsdServiceInfo); | 
 | 232 |     method public void onResolveFailed(android.net.nsd.NsdServiceInfo, int); | 
 | 233 |     method public void onServiceResolved(android.net.nsd.NsdServiceInfo); | 
 | 234 |     method public default void onStopResolutionFailed(@NonNull android.net.nsd.NsdServiceInfo, int); | 
 | 235 |   } | 
 | 236 |  | 
 | 237 |   public static interface NsdManager.ServiceInfoCallback { | 
 | 238 |     method public void onServiceInfoCallbackRegistrationFailed(int); | 
 | 239 |     method public void onServiceInfoCallbackUnregistered(); | 
 | 240 |     method public void onServiceLost(); | 
 | 241 |     method public void onServiceUpdated(@NonNull android.net.nsd.NsdServiceInfo); | 
 | 242 |   } | 
 | 243 |  | 
 | 244 |   public final class NsdServiceInfo implements android.os.Parcelable { | 
 | 245 |     ctor public NsdServiceInfo(); | 
 | 246 |     method public int describeContents(); | 
 | 247 |     method public java.util.Map<java.lang.String,byte[]> getAttributes(); | 
 | 248 |     method @Deprecated public java.net.InetAddress getHost(); | 
 | 249 |     method @NonNull public java.util.List<java.net.InetAddress> getHostAddresses(); | 
 | 250 |     method @Nullable public android.net.Network getNetwork(); | 
 | 251 |     method public int getPort(); | 
 | 252 |     method public String getServiceName(); | 
 | 253 |     method public String getServiceType(); | 
 | 254 |     method public void removeAttribute(String); | 
 | 255 |     method public void setAttribute(String, String); | 
 | 256 |     method @Deprecated public void setHost(java.net.InetAddress); | 
 | 257 |     method public void setHostAddresses(@NonNull java.util.List<java.net.InetAddress>); | 
 | 258 |     method public void setNetwork(@Nullable android.net.Network); | 
 | 259 |     method public void setPort(int); | 
 | 260 |     method public void setServiceName(String); | 
 | 261 |     method public void setServiceType(String); | 
 | 262 |     method public void writeToParcel(android.os.Parcel, int); | 
 | 263 |     field @NonNull public static final android.os.Parcelable.Creator<android.net.nsd.NsdServiceInfo> CREATOR; | 
 | 264 |   } | 
 | 265 |  | 
 | 266 | } | 
 | 267 |  |