code
stringlengths 11
173k
| docstring
stringlengths 2
593k
| func_name
stringlengths 2
189
| language
stringclasses 1
value | repo
stringclasses 844
values | path
stringlengths 11
294
| url
stringlengths 60
339
| license
stringclasses 4
values |
---|---|---|---|---|---|---|---|
public final void setKeyEntry(String alias, byte[] key,
Certificate[] chain)
throws KeyStoreException
{
if (!initialized) {
throw new KeyStoreException("Uninitialized keystore");
}
keyStoreSpi.engineSetKeyEntry(alias, key, chain);
} |
Assigns the given key (that has already been protected) to the given
alias.
<p>If the protected key is of type
{@code java.security.PrivateKey}, it must be accompanied by a
certificate chain certifying the corresponding public key. If the
underlying keystore implementation is of type {@code jks},
{@code key} must be encoded as an
{@code EncryptedPrivateKeyInfo} as defined in the PKCS #8 standard.
<p>If the given alias already exists, the keystore information
associated with it is overridden by the given key (and possibly
certificate chain).
@param alias the alias name
@param key the key (in protected format) to be associated with the alias
@param chain the certificate chain for the corresponding public
key (only useful if the protected key is of type
{@code java.security.PrivateKey}).
@exception KeyStoreException if the keystore has not been initialized
(loaded), or if this operation fails for some other reason.
| TrustedCertificateEntry::setKeyEntry | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public final void setCertificateEntry(String alias, Certificate cert)
throws KeyStoreException
{
if (!initialized) {
throw new KeyStoreException("Uninitialized keystore");
}
keyStoreSpi.engineSetCertificateEntry(alias, cert);
} |
Assigns the given trusted certificate to the given alias.
<p> If the given alias identifies an existing entry
created by a call to {@code setCertificateEntry},
or created by a call to {@code setEntry} with a
{@code TrustedCertificateEntry},
the trusted certificate in the existing entry
is overridden by the given certificate.
@param alias the alias name
@param cert the certificate
@exception KeyStoreException if the keystore has not been initialized,
or the given alias already exists and does not identify an
entry containing a trusted certificate,
or this operation fails for some other reason.
| TrustedCertificateEntry::setCertificateEntry | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public final void deleteEntry(String alias)
throws KeyStoreException
{
if (!initialized) {
throw new KeyStoreException("Uninitialized keystore");
}
keyStoreSpi.engineDeleteEntry(alias);
} |
Deletes the entry identified by the given alias from this keystore.
@param alias the alias name
@exception KeyStoreException if the keystore has not been initialized,
or if the entry cannot be removed.
| TrustedCertificateEntry::deleteEntry | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public final Enumeration<String> aliases()
throws KeyStoreException
{
if (!initialized) {
throw new KeyStoreException("Uninitialized keystore");
}
return keyStoreSpi.engineAliases();
} |
Lists all the alias names of this keystore.
@return enumeration of the alias names
@exception KeyStoreException if the keystore has not been initialized
(loaded).
| TrustedCertificateEntry::aliases | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public final boolean containsAlias(String alias)
throws KeyStoreException
{
if (!initialized) {
throw new KeyStoreException("Uninitialized keystore");
}
return keyStoreSpi.engineContainsAlias(alias);
} |
Checks if the given alias exists in this keystore.
@param alias the alias name
@return true if the alias exists, false otherwise
@exception KeyStoreException if the keystore has not been initialized
(loaded).
| TrustedCertificateEntry::containsAlias | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public final int size()
throws KeyStoreException
{
if (!initialized) {
throw new KeyStoreException("Uninitialized keystore");
}
return keyStoreSpi.engineSize();
} |
Retrieves the number of entries in this keystore.
@return the number of entries in this keystore
@exception KeyStoreException if the keystore has not been initialized
(loaded).
| TrustedCertificateEntry::size | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public final boolean isKeyEntry(String alias)
throws KeyStoreException
{
if (!initialized) {
throw new KeyStoreException("Uninitialized keystore");
}
return keyStoreSpi.engineIsKeyEntry(alias);
} |
Returns true if the entry identified by the given alias
was created by a call to {@code setKeyEntry},
or created by a call to {@code setEntry} with a
{@code PrivateKeyEntry} or a {@code SecretKeyEntry}.
@param alias the alias for the keystore entry to be checked
@return true if the entry identified by the given alias is a
key-related entry, false otherwise.
@exception KeyStoreException if the keystore has not been initialized
(loaded).
| TrustedCertificateEntry::isKeyEntry | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public final boolean isCertificateEntry(String alias)
throws KeyStoreException
{
if (!initialized) {
throw new KeyStoreException("Uninitialized keystore");
}
return keyStoreSpi.engineIsCertificateEntry(alias);
} |
Returns true if the entry identified by the given alias
was created by a call to {@code setCertificateEntry},
or created by a call to {@code setEntry} with a
{@code TrustedCertificateEntry}.
@param alias the alias for the keystore entry to be checked
@return true if the entry identified by the given alias contains a
trusted certificate, false otherwise.
@exception KeyStoreException if the keystore has not been initialized
(loaded).
| TrustedCertificateEntry::isCertificateEntry | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public final String getCertificateAlias(Certificate cert)
throws KeyStoreException
{
if (!initialized) {
throw new KeyStoreException("Uninitialized keystore");
}
return keyStoreSpi.engineGetCertificateAlias(cert);
} |
Returns the (alias) name of the first keystore entry whose certificate
matches the given certificate.
<p> This method attempts to match the given certificate with each
keystore entry. If the entry being considered was
created by a call to {@code setCertificateEntry},
or created by a call to {@code setEntry} with a
{@code TrustedCertificateEntry},
then the given certificate is compared to that entry's certificate.
<p> If the entry being considered was
created by a call to {@code setKeyEntry},
or created by a call to {@code setEntry} with a
{@code PrivateKeyEntry},
then the given certificate is compared to the first
element of that entry's certificate chain.
@param cert the certificate to match with.
@return the alias name of the first entry with a matching certificate,
or null if no such entry exists in this keystore.
@exception KeyStoreException if the keystore has not been initialized
(loaded).
| TrustedCertificateEntry::getCertificateAlias | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public final void store(OutputStream stream, char[] password)
throws KeyStoreException, IOException, NoSuchAlgorithmException,
CertificateException
{
if (!initialized) {
throw new KeyStoreException("Uninitialized keystore");
}
keyStoreSpi.engineStore(stream, password);
} |
Stores this keystore to the given output stream, and protects its
integrity with the given password.
@param stream the output stream to which this keystore is written.
@param password the password to generate the keystore integrity check
@exception KeyStoreException if the keystore has not been initialized
(loaded).
@exception IOException if there was an I/O problem with data
@exception NoSuchAlgorithmException if the appropriate data integrity
algorithm could not be found
@exception CertificateException if any of the certificates included in
the keystore data could not be stored
| TrustedCertificateEntry::store | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public final void store(LoadStoreParameter param)
throws KeyStoreException, IOException,
NoSuchAlgorithmException, CertificateException {
if (!initialized) {
throw new KeyStoreException("Uninitialized keystore");
}
keyStoreSpi.engineStore(param);
} |
Stores this keystore using the given {@code LoadStoreParameter}.
@param param the {@code LoadStoreParameter}
that specifies how to store the keystore,
which may be {@code null}
@exception IllegalArgumentException if the given
{@code LoadStoreParameter}
input is not recognized
@exception KeyStoreException if the keystore has not been initialized
(loaded)
@exception IOException if there was an I/O problem with data
@exception NoSuchAlgorithmException if the appropriate data integrity
algorithm could not be found
@exception CertificateException if any of the certificates included in
the keystore data could not be stored
@since 1.5
| TrustedCertificateEntry::store | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public final void load(InputStream stream, char[] password)
throws IOException, NoSuchAlgorithmException, CertificateException
{
keyStoreSpi.engineLoad(stream, password);
initialized = true;
} |
Loads this KeyStore from the given input stream.
<p>A password may be given to unlock the keystore
(e.g. the keystore resides on a hardware token device),
or to check the integrity of the keystore data.
If a password is not given for integrity checking,
then integrity checking is not performed.
<p>In order to create an empty keystore, or if the keystore cannot
be initialized from a stream, pass {@code null}
as the {@code stream} argument.
<p> Note that if this keystore has already been loaded, it is
reinitialized and loaded again from the given input stream.
@param stream the input stream from which the keystore is loaded,
or {@code null}
@param password the password used to check the integrity of
the keystore, the password used to unlock the keystore,
or {@code null}
@exception IOException if there is an I/O or format problem with the
keystore data, if a password is required but not given,
or if the given password was incorrect. If the error is due to a
wrong password, the {@link Throwable#getCause cause} of the
{@code IOException} should be an
{@code UnrecoverableKeyException}
@exception NoSuchAlgorithmException if the algorithm used to check
the integrity of the keystore cannot be found
@exception CertificateException if any of the certificates in the
keystore could not be loaded
| TrustedCertificateEntry::load | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public final void load(LoadStoreParameter param)
throws IOException, NoSuchAlgorithmException,
CertificateException {
keyStoreSpi.engineLoad(param);
initialized = true;
} |
Loads this keystore using the given {@code LoadStoreParameter}.
<p> Note that if this KeyStore has already been loaded, it is
reinitialized and loaded again from the given parameter.
@param param the {@code LoadStoreParameter}
that specifies how to load the keystore,
which may be {@code null}
@exception IllegalArgumentException if the given
{@code LoadStoreParameter}
input is not recognized
@exception IOException if there is an I/O or format problem with the
keystore data. If the error is due to an incorrect
{@code ProtectionParameter} (e.g. wrong password)
the {@link Throwable#getCause cause} of the
{@code IOException} should be an
{@code UnrecoverableKeyException}
@exception NoSuchAlgorithmException if the algorithm used to check
the integrity of the keystore cannot be found
@exception CertificateException if any of the certificates in the
keystore could not be loaded
@since 1.5
| TrustedCertificateEntry::load | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public final Entry getEntry(String alias, ProtectionParameter protParam)
throws NoSuchAlgorithmException, UnrecoverableEntryException,
KeyStoreException {
if (alias == null) {
throw new NullPointerException("invalid null input");
}
if (!initialized) {
throw new KeyStoreException("Uninitialized keystore");
}
return keyStoreSpi.engineGetEntry(alias, protParam);
} |
Gets a keystore {@code Entry} for the specified alias
with the specified protection parameter.
@param alias get the keystore {@code Entry} for this alias
@param protParam the {@code ProtectionParameter}
used to protect the {@code Entry},
which may be {@code null}
@return the keystore {@code Entry} for the specified alias,
or {@code null} if there is no such entry
@exception NullPointerException if
{@code alias} is {@code null}
@exception NoSuchAlgorithmException if the algorithm for recovering the
entry cannot be found
@exception UnrecoverableEntryException if the specified
{@code protParam} were insufficient or invalid
@exception UnrecoverableKeyException if the entry is a
{@code PrivateKeyEntry} or {@code SecretKeyEntry}
and the specified {@code protParam} does not contain
the information needed to recover the key (e.g. wrong password)
@exception KeyStoreException if the keystore has not been initialized
(loaded).
@see #setEntry(String, KeyStore.Entry, KeyStore.ProtectionParameter)
@since 1.5
| TrustedCertificateEntry::getEntry | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public final void setEntry(String alias, Entry entry,
ProtectionParameter protParam)
throws KeyStoreException {
if (alias == null || entry == null) {
throw new NullPointerException("invalid null input");
}
if (!initialized) {
throw new KeyStoreException("Uninitialized keystore");
}
keyStoreSpi.engineSetEntry(alias, entry, protParam);
} |
Saves a keystore {@code Entry} under the specified alias.
The protection parameter is used to protect the
{@code Entry}.
<p> If an entry already exists for the specified alias,
it is overridden.
@param alias save the keystore {@code Entry} under this alias
@param entry the {@code Entry} to save
@param protParam the {@code ProtectionParameter}
used to protect the {@code Entry},
which may be {@code null}
@exception NullPointerException if
{@code alias} or {@code entry}
is {@code null}
@exception KeyStoreException if the keystore has not been initialized
(loaded), or if this operation fails for some other reason
@see #getEntry(String, KeyStore.ProtectionParameter)
@since 1.5
| TrustedCertificateEntry::setEntry | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
protected Builder() {
// empty
} |
Construct a new Builder.
| Builder::Builder | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public static Builder newInstance(final KeyStore keyStore,
final ProtectionParameter protectionParameter) {
if ((keyStore == null) || (protectionParameter == null)) {
throw new NullPointerException();
}
if (keyStore.initialized == false) {
throw new IllegalArgumentException("KeyStore not initialized");
}
return new Builder() {
private volatile boolean getCalled;
public KeyStore getKeyStore() {
getCalled = true;
return keyStore;
}
public ProtectionParameter getProtectionParameter(String alias)
{
if (alias == null) {
throw new NullPointerException();
}
if (getCalled == false) {
throw new IllegalStateException
("getKeyStore() must be called first");
}
return protectionParameter;
}
};
} |
Returns a new Builder that encapsulates the given KeyStore.
The {@linkplain #getKeyStore} method of the returned object
will return {@code keyStore}, the {@linkplain
#getProtectionParameter getProtectionParameter()} method will
return {@code protectionParameters}.
<p> This is useful if an existing KeyStore object needs to be
used with Builder-based APIs.
@return a new Builder object
@param keyStore the KeyStore to be encapsulated
@param protectionParameter the ProtectionParameter used to
protect the KeyStore entries
@throws NullPointerException if keyStore or
protectionParameters is null
@throws IllegalArgumentException if the keyStore has not been
initialized
| Builder::newInstance | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public static Builder newInstance(String type, Provider provider,
File file, ProtectionParameter protection) {
if ((type == null) || (file == null) || (protection == null)) {
throw new NullPointerException();
}
if ((protection instanceof PasswordProtection == false) &&
(protection instanceof CallbackHandlerProtection == false)) {
throw new IllegalArgumentException
("Protection must be PasswordProtection or " +
"CallbackHandlerProtection");
}
if (file.isFile() == false) {
throw new IllegalArgumentException
("File does not exist or it does not refer " +
"to a normal file: " + file);
}
return new FileBuilder(type, provider, file, protection,
AccessController.getContext());
} |
Returns a new Builder object.
<p>The first call to the {@link #getKeyStore} method on the returned
builder will create a KeyStore of type {@code type} and call
its {@link KeyStore#load load()} method.
The {@code inputStream} argument is constructed from
{@code file}.
If {@code protection} is a
{@code PasswordProtection}, the password is obtained by
calling the {@code getPassword} method.
Otherwise, if {@code protection} is a
{@code CallbackHandlerProtection}, the password is obtained
by invoking the CallbackHandler.
<p>Subsequent calls to {@link #getKeyStore} return the same object
as the initial call. If the initial call to failed with a
KeyStoreException, subsequent calls also throw a
KeyStoreException.
<p>The KeyStore is instantiated from {@code provider} if
non-null. Otherwise, all installed providers are searched.
<p>Calls to {@link #getProtectionParameter getProtectionParameter()}
will return a {@link KeyStore.PasswordProtection PasswordProtection}
object encapsulating the password that was used to invoke the
{@code load} method.
<p><em>Note</em> that the {@link #getKeyStore} method is executed
within the {@link AccessControlContext} of the code invoking this
method.
@return a new Builder object
@param type the type of KeyStore to be constructed
@param provider the provider from which the KeyStore is to
be instantiated (or null)
@param file the File that contains the KeyStore data
@param protection the ProtectionParameter securing the KeyStore data
@throws NullPointerException if type, file or protection is null
@throws IllegalArgumentException if protection is not an instance
of either PasswordProtection or CallbackHandlerProtection; or
if file does not exist or does not refer to a normal file
| Builder::newInstance | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public static Builder newInstance(final String type,
final Provider provider, final ProtectionParameter protection) {
if ((type == null) || (protection == null)) {
throw new NullPointerException();
}
final AccessControlContext context = AccessController.getContext();
return new Builder() {
private volatile boolean getCalled;
private IOException oldException;
private final PrivilegedExceptionAction<KeyStore> action
= new PrivilegedExceptionAction<KeyStore>() {
public KeyStore run() throws Exception {
KeyStore ks;
if (provider == null) {
ks = KeyStore.getInstance(type);
} else {
ks = KeyStore.getInstance(type, provider);
}
LoadStoreParameter param = new SimpleLoadStoreParameter(protection);
if (protection instanceof CallbackHandlerProtection == false) {
ks.load(param);
} else {
// when using a CallbackHandler,
// reprompt if the password is wrong
int tries = 0;
while (true) {
tries++;
try {
ks.load(param);
break;
} catch (IOException e) {
if (e.getCause() instanceof UnrecoverableKeyException) {
if (tries < MAX_CALLBACK_TRIES) {
continue;
} else {
oldException = e;
}
}
throw e;
}
}
}
getCalled = true;
return ks;
}
};
public synchronized KeyStore getKeyStore()
throws KeyStoreException {
if (oldException != null) {
throw new KeyStoreException
("Previous KeyStore instantiation failed",
oldException);
}
try {
return AccessController.doPrivileged(action, context);
} catch (PrivilegedActionException e) {
Throwable cause = e.getCause();
throw new KeyStoreException
("KeyStore instantiation failed", cause);
}
}
public ProtectionParameter getProtectionParameter(String alias)
{
if (alias == null) {
throw new NullPointerException();
}
if (getCalled == false) {
throw new IllegalStateException
("getKeyStore() must be called first");
}
return protection;
}
};
} |
Returns a new Builder object.
<p>Each call to the {@link #getKeyStore} method on the returned
builder will return a new KeyStore object of type {@code type}.
Its {@link KeyStore#load(KeyStore.LoadStoreParameter) load()}
method is invoked using a
{@code LoadStoreParameter} that encapsulates
{@code protection}.
<p>The KeyStore is instantiated from {@code provider} if
non-null. Otherwise, all installed providers are searched.
<p>Calls to {@link #getProtectionParameter getProtectionParameter()}
will return {@code protection}.
<p><em>Note</em> that the {@link #getKeyStore} method is executed
within the {@link AccessControlContext} of the code invoking this
method.
@return a new Builder object
@param type the type of KeyStore to be constructed
@param provider the provider from which the KeyStore is to
be instantiated (or null)
@param protection the ProtectionParameter securing the Keystore
@throws NullPointerException if type or protection is null
| FileBuilder::newInstance | java | Reginer/aosp-android-jar | android-32/src/java/security/KeyStore.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/security/KeyStore.java | MIT |
public int describeContents() {
return 0;
} |
A class representing connection information about a Wi-Fi p2p group
{@see WifiP2pManager}
public class WifiP2pInfo implements Parcelable {
/** Indicates if a p2p group has been successfully formed
public boolean groupFormed;
/** Indicates if the current device is the group owner
public boolean isGroupOwner;
/** Group owner address
public InetAddress groupOwnerAddress;
public WifiP2pInfo() {
}
public String toString() {
StringBuffer sbuf = new StringBuffer();
sbuf.append("groupFormed: ").append(groupFormed)
.append(" isGroupOwner: ").append(isGroupOwner)
.append(" groupOwnerAddress: ").append(groupOwnerAddress);
return sbuf.toString();
}
/** Implement the Parcelable interface | WifiP2pInfo::describeContents | java | Reginer/aosp-android-jar | android-31/src/android/net/wifi/p2p/WifiP2pInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/android/net/wifi/p2p/WifiP2pInfo.java | MIT |
public WifiP2pInfo(WifiP2pInfo source) {
if (source != null) {
groupFormed = source.groupFormed;
isGroupOwner = source.isGroupOwner;
groupOwnerAddress = source.groupOwnerAddress;
}
} |
A class representing connection information about a Wi-Fi p2p group
{@see WifiP2pManager}
public class WifiP2pInfo implements Parcelable {
/** Indicates if a p2p group has been successfully formed
public boolean groupFormed;
/** Indicates if the current device is the group owner
public boolean isGroupOwner;
/** Group owner address
public InetAddress groupOwnerAddress;
public WifiP2pInfo() {
}
public String toString() {
StringBuffer sbuf = new StringBuffer();
sbuf.append("groupFormed: ").append(groupFormed)
.append(" isGroupOwner: ").append(isGroupOwner)
.append(" groupOwnerAddress: ").append(groupOwnerAddress);
return sbuf.toString();
}
/** Implement the Parcelable interface
public int describeContents() {
return 0;
}
/** copy constructor | WifiP2pInfo::WifiP2pInfo | java | Reginer/aosp-android-jar | android-31/src/android/net/wifi/p2p/WifiP2pInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/android/net/wifi/p2p/WifiP2pInfo.java | MIT |
public void writeToParcel(Parcel dest, int flags) {
dest.writeByte(groupFormed ? (byte)1 : (byte)0);
dest.writeByte(isGroupOwner ? (byte)1 : (byte)0);
if (groupOwnerAddress != null) {
dest.writeByte((byte)1);
dest.writeByteArray(groupOwnerAddress.getAddress());
} else {
dest.writeByte((byte)0);
}
} |
A class representing connection information about a Wi-Fi p2p group
{@see WifiP2pManager}
public class WifiP2pInfo implements Parcelable {
/** Indicates if a p2p group has been successfully formed
public boolean groupFormed;
/** Indicates if the current device is the group owner
public boolean isGroupOwner;
/** Group owner address
public InetAddress groupOwnerAddress;
public WifiP2pInfo() {
}
public String toString() {
StringBuffer sbuf = new StringBuffer();
sbuf.append("groupFormed: ").append(groupFormed)
.append(" isGroupOwner: ").append(isGroupOwner)
.append(" groupOwnerAddress: ").append(groupOwnerAddress);
return sbuf.toString();
}
/** Implement the Parcelable interface
public int describeContents() {
return 0;
}
/** copy constructor
public WifiP2pInfo(WifiP2pInfo source) {
if (source != null) {
groupFormed = source.groupFormed;
isGroupOwner = source.isGroupOwner;
groupOwnerAddress = source.groupOwnerAddress;
}
}
/** Implement the Parcelable interface | WifiP2pInfo::writeToParcel | java | Reginer/aosp-android-jar | android-31/src/android/net/wifi/p2p/WifiP2pInfo.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/android/net/wifi/p2p/WifiP2pInfo.java | MIT |
public static LongBuffer allocate(int capacity) {
if (capacity < 0)
throw new IllegalArgumentException();
return new HeapLongBuffer(capacity, capacity);
} |
Allocates a new long buffer.
<p> The new buffer's position will be zero, its limit will be its
capacity, its mark will be undefined, and each of its elements will be
initialized to zero. It will have a {@link #array backing array},
and its {@link #arrayOffset array offset} will be zero.
@param capacity
The new buffer's capacity, in longs
@return The new long buffer
@throws IllegalArgumentException
If the <tt>capacity</tt> is a negative integer
| LongBuffer::allocate | java | Reginer/aosp-android-jar | android-32/src/java/nio/LongBuffer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/nio/LongBuffer.java | MIT |
public static LongBuffer wrap(long[] array,
int offset, int length)
{
try {
return new HeapLongBuffer(array, offset, length);
} catch (IllegalArgumentException x) {
throw new IndexOutOfBoundsException();
}
} |
Wraps a long array into a buffer.
<p> The new buffer will be backed by the given long array;
that is, modifications to the buffer will cause the array to be modified
and vice versa. The new buffer's capacity will be
<tt>array.length</tt>, its position will be <tt>offset</tt>, its limit
will be <tt>offset + length</tt>, and its mark will be undefined. Its
{@link #array backing array} will be the given array, and
its {@link #arrayOffset array offset} will be zero. </p>
@param array
The array that will back the new buffer
@param offset
The offset of the subarray to be used; must be non-negative and
no larger than <tt>array.length</tt>. The new buffer's position
will be set to this value.
@param length
The length of the subarray to be used;
must be non-negative and no larger than
<tt>array.length - offset</tt>.
The new buffer's limit will be set to <tt>offset + length</tt>.
@return The new long buffer
@throws IndexOutOfBoundsException
If the preconditions on the <tt>offset</tt> and <tt>length</tt>
parameters do not hold
| LongBuffer::wrap | java | Reginer/aosp-android-jar | android-32/src/java/nio/LongBuffer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/nio/LongBuffer.java | MIT |
public static LongBuffer wrap(long[] array) {
return wrap(array, 0, array.length);
} |
Wraps a long array into a buffer.
<p> The new buffer will be backed by the given long array;
that is, modifications to the buffer will cause the array to be modified
and vice versa. The new buffer's capacity and limit will be
<tt>array.length</tt>, its position will be zero, and its mark will be
undefined. Its {@link #array backing array} will be the
given array, and its {@link #arrayOffset array offset>} will
be zero. </p>
@param array
The array that will back this buffer
@return The new long buffer
| LongBuffer::wrap | java | Reginer/aosp-android-jar | android-32/src/java/nio/LongBuffer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/nio/LongBuffer.java | MIT |
public LongBuffer get(long[] dst, int offset, int length) {
checkBounds(offset, length, dst.length);
if (length > remaining())
throw new BufferUnderflowException();
int end = offset + length;
for (int i = offset; i < end; i++)
dst[i] = get();
return this;
} |
Relative bulk <i>get</i> method.
<p> This method transfers longs from this buffer into the given
destination array. If there are fewer longs remaining in the
buffer than are required to satisfy the request, that is, if
<tt>length</tt> <tt>></tt> <tt>remaining()</tt>, then no
longs are transferred and a {@link BufferUnderflowException} is
thrown.
<p> Otherwise, this method copies <tt>length</tt> longs from this
buffer into the given array, starting at the current position of this
buffer and at the given offset in the array. The position of this
buffer is then incremented by <tt>length</tt>.
<p> In other words, an invocation of this method of the form
<tt>src.get(dst, off, len)</tt> has exactly the same effect as
the loop
<pre>{@code
for (int i = off; i < off + len; i++)
dst[i] = src.get();
}</pre>
except that it first checks that there are sufficient longs in
this buffer and it is potentially much more efficient.
@param dst
The array into which longs are to be written
@param offset
The offset within the array of the first long to be
written; must be non-negative and no larger than
<tt>dst.length</tt>
@param length
The maximum number of longs to be written to the given
array; must be non-negative and no larger than
<tt>dst.length - offset</tt>
@return This buffer
@throws BufferUnderflowException
If there are fewer than <tt>length</tt> longs
remaining in this buffer
@throws IndexOutOfBoundsException
If the preconditions on the <tt>offset</tt> and <tt>length</tt>
parameters do not hold
| LongBuffer::get | java | Reginer/aosp-android-jar | android-32/src/java/nio/LongBuffer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/nio/LongBuffer.java | MIT |
public LongBuffer get(long[] dst) {
return get(dst, 0, dst.length);
} |
Relative bulk <i>get</i> method.
<p> This method transfers longs from this buffer into the given
destination array. An invocation of this method of the form
<tt>src.get(a)</tt> behaves in exactly the same way as the invocation
<pre>
src.get(a, 0, a.length) </pre>
@param dst
The destination array
@return This buffer
@throws BufferUnderflowException
If there are fewer than <tt>length</tt> longs
remaining in this buffer
| LongBuffer::get | java | Reginer/aosp-android-jar | android-32/src/java/nio/LongBuffer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/nio/LongBuffer.java | MIT |
public LongBuffer put(LongBuffer src) {
if (src == this)
throw new IllegalArgumentException();
if (isReadOnly())
throw new ReadOnlyBufferException();
int n = src.remaining();
if (n > remaining())
throw new BufferOverflowException();
for (int i = 0; i < n; i++)
put(src.get());
return this;
} |
Relative bulk <i>put</i> method <i>(optional operation)</i>.
<p> This method transfers the longs remaining in the given source
buffer into this buffer. If there are more longs remaining in the
source buffer than in this buffer, that is, if
<tt>src.remaining()</tt> <tt>></tt> <tt>remaining()</tt>,
then no longs are transferred and a {@link
BufferOverflowException} is thrown.
<p> Otherwise, this method copies
<i>n</i> = <tt>src.remaining()</tt> longs from the given
buffer into this buffer, starting at each buffer's current position.
The positions of both buffers are then incremented by <i>n</i>.
<p> In other words, an invocation of this method of the form
<tt>dst.put(src)</tt> has exactly the same effect as the loop
<pre>
while (src.hasRemaining())
dst.put(src.get()); </pre>
except that it first checks that there is sufficient space in this
buffer and it is potentially much more efficient.
@param src
The source buffer from which longs are to be read;
must not be this buffer
@return This buffer
@throws BufferOverflowException
If there is insufficient space in this buffer
for the remaining longs in the source buffer
@throws IllegalArgumentException
If the source buffer is this buffer
@throws ReadOnlyBufferException
If this buffer is read-only
| LongBuffer::put | java | Reginer/aosp-android-jar | android-32/src/java/nio/LongBuffer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/nio/LongBuffer.java | MIT |
public LongBuffer put(long[] src, int offset, int length) {
checkBounds(offset, length, src.length);
if (length > remaining())
throw new BufferOverflowException();
int end = offset + length;
for (int i = offset; i < end; i++)
this.put(src[i]);
return this;
} |
Relative bulk <i>put</i> method <i>(optional operation)</i>.
<p> This method transfers longs into this buffer from the given
source array. If there are more longs to be copied from the array
than remain in this buffer, that is, if
<tt>length</tt> <tt>></tt> <tt>remaining()</tt>, then no
longs are transferred and a {@link BufferOverflowException} is
thrown.
<p> Otherwise, this method copies <tt>length</tt> longs from the
given array into this buffer, starting at the given offset in the array
and at the current position of this buffer. The position of this buffer
is then incremented by <tt>length</tt>.
<p> In other words, an invocation of this method of the form
<tt>dst.put(src, off, len)</tt> has exactly the same effect as
the loop
<pre>{@code
for (int i = off; i < off + len; i++)
dst.put(a[i]);
}</pre>
except that it first checks that there is sufficient space in this
buffer and it is potentially much more efficient.
@param src
The array from which longs are to be read
@param offset
The offset within the array of the first long to be read;
must be non-negative and no larger than <tt>array.length</tt>
@param length
The number of longs to be read from the given array;
must be non-negative and no larger than
<tt>array.length - offset</tt>
@return This buffer
@throws BufferOverflowException
If there is insufficient space in this buffer
@throws IndexOutOfBoundsException
If the preconditions on the <tt>offset</tt> and <tt>length</tt>
parameters do not hold
@throws ReadOnlyBufferException
If this buffer is read-only
| LongBuffer::put | java | Reginer/aosp-android-jar | android-32/src/java/nio/LongBuffer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/nio/LongBuffer.java | MIT |
public final LongBuffer put(long[] src) {
return put(src, 0, src.length);
} |
Relative bulk <i>put</i> method <i>(optional operation)</i>.
<p> This method transfers the entire content of the given source
long array into this buffer. An invocation of this method of the
form <tt>dst.put(a)</tt> behaves in exactly the same way as the
invocation
<pre>
dst.put(a, 0, a.length) </pre>
@param src
The source array
@return This buffer
@throws BufferOverflowException
If there is insufficient space in this buffer
@throws ReadOnlyBufferException
If this buffer is read-only
| LongBuffer::put | java | Reginer/aosp-android-jar | android-32/src/java/nio/LongBuffer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/nio/LongBuffer.java | MIT |
public final boolean hasArray() {
return (hb != null) && !isReadOnly;
} |
Tells whether or not this buffer is backed by an accessible long
array.
<p> If this method returns <tt>true</tt> then the {@link #array() array}
and {@link #arrayOffset() arrayOffset} methods may safely be invoked.
</p>
@return <tt>true</tt> if, and only if, this buffer
is backed by an array and is not read-only
| LongBuffer::hasArray | java | Reginer/aosp-android-jar | android-32/src/java/nio/LongBuffer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/nio/LongBuffer.java | MIT |
public final long[] array() {
if (hb == null)
throw new UnsupportedOperationException();
if (isReadOnly)
throw new ReadOnlyBufferException();
return hb;
} |
Returns the long array that backs this
buffer <i>(optional operation)</i>.
<p> Modifications to this buffer's content will cause the returned
array's content to be modified, and vice versa.
<p> Invoke the {@link #hasArray hasArray} method before invoking this
method in order to ensure that this buffer has an accessible backing
array. </p>
@return The array that backs this buffer
@throws ReadOnlyBufferException
If this buffer is backed by an array but is read-only
@throws UnsupportedOperationException
If this buffer is not backed by an accessible array
| LongBuffer::array | java | Reginer/aosp-android-jar | android-32/src/java/nio/LongBuffer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/nio/LongBuffer.java | MIT |
public final int arrayOffset() {
if (hb == null)
throw new UnsupportedOperationException();
if (isReadOnly)
throw new ReadOnlyBufferException();
return offset;
} |
Returns the offset within this buffer's backing array of the first
element of the buffer <i>(optional operation)</i>.
<p> If this buffer is backed by an array then buffer position <i>p</i>
corresponds to array index <i>p</i> + <tt>arrayOffset()</tt>.
<p> Invoke the {@link #hasArray hasArray} method before invoking this
method in order to ensure that this buffer has an accessible backing
array. </p>
@return The offset within this buffer's array
of the first element of the buffer
@throws ReadOnlyBufferException
If this buffer is backed by an array but is read-only
@throws UnsupportedOperationException
If this buffer is not backed by an accessible array
| LongBuffer::arrayOffset | java | Reginer/aosp-android-jar | android-32/src/java/nio/LongBuffer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/nio/LongBuffer.java | MIT |
public String toString() {
StringBuffer sb = new StringBuffer();
sb.append(getClass().getName());
sb.append("[pos=");
sb.append(position());
sb.append(" lim=");
sb.append(limit());
sb.append(" cap=");
sb.append(capacity());
sb.append("]");
return sb.toString();
} |
Returns a string summarizing the state of this buffer.
@return A summary string
| presentAfter::toString | java | Reginer/aosp-android-jar | android-32/src/java/nio/LongBuffer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/nio/LongBuffer.java | MIT |
public int hashCode() {
int h = 1;
int p = position();
for (int i = limit() - 1; i >= p; i--)
h = 31 * h + (int) get(i);
return h;
} |
Returns the current hash code of this buffer.
<p> The hash code of a long buffer depends only upon its remaining
elements; that is, upon the elements from <tt>position()</tt> up to, and
including, the element at <tt>limit()</tt> - <tt>1</tt>.
<p> Because buffer hash codes are content-dependent, it is inadvisable
to use buffers as keys in hash maps or similar data structures unless it
is known that their contents will not change. </p>
@return The current hash code of this buffer
| presentAfter::hashCode | java | Reginer/aosp-android-jar | android-32/src/java/nio/LongBuffer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/nio/LongBuffer.java | MIT |
public boolean equals(Object ob) {
if (this == ob)
return true;
if (!(ob instanceof LongBuffer))
return false;
LongBuffer that = (LongBuffer)ob;
if (this.remaining() != that.remaining())
return false;
int p = this.position();
for (int i = this.limit() - 1, j = that.limit() - 1; i >= p; i--, j--)
if (!equals(this.get(i), that.get(j)))
return false;
return true;
} |
Tells whether or not this buffer is equal to another object.
<p> Two long buffers are equal if, and only if,
<ol>
<li><p> They have the same element type, </p></li>
<li><p> They have the same number of remaining elements, and
</p></li>
<li><p> The two sequences of remaining elements, considered
independently of their starting positions, are pointwise equal.
</p></li>
</ol>
<p> A long buffer is not equal to any other type of object. </p>
@param ob The object to which this buffer is to be compared
@return <tt>true</tt> if, and only if, this buffer is equal to the
given object
| presentAfter::equals | java | Reginer/aosp-android-jar | android-32/src/java/nio/LongBuffer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/nio/LongBuffer.java | MIT |
public int compareTo(LongBuffer that) {
int n = this.position() + Math.min(this.remaining(), that.remaining());
for (int i = this.position(), j = that.position(); i < n; i++, j++) {
int cmp = compare(this.get(i), that.get(j));
if (cmp != 0)
return cmp;
}
return this.remaining() - that.remaining();
} |
Compares this buffer to another.
<p> Two long buffers are compared by comparing their sequences of
remaining elements lexicographically, without regard to the starting
position of each sequence within its corresponding buffer.
Pairs of {@code long} elements are compared as if by invoking
{@link Long#compare(long,long)}.
<p> A long buffer is not comparable to any other type of object.
@return A negative integer, zero, or a positive integer as this buffer
is less than, equal to, or greater than the given buffer
| presentAfter::compareTo | java | Reginer/aosp-android-jar | android-32/src/java/nio/LongBuffer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-32/src/java/nio/LongBuffer.java | MIT |
private int peekNextExternalToken() throws IOException, XmlPullParserException {
while (true) {
final int token = peekNextToken();
switch (token) {
case ATTRIBUTE:
consumeToken();
continue;
default:
return token;
}
}
} |
Peek at the next "external" token without consuming it.
<p>
External tokens, such as {@link #START_TAG}, are expected by typical
{@link XmlPullParser} clients. In contrast, internal tokens, such as
{@link #ATTRIBUTE}, are not expected by typical clients.
<p>
This method consumes any internal events until it reaches the next
external event.
| BinaryXmlPullParser::peekNextExternalToken | java | Reginer/aosp-android-jar | android-35/src/com/android/modules/utils/BinaryXmlPullParser.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/modules/utils/BinaryXmlPullParser.java | MIT |
private int peekNextToken() throws IOException {
return mIn.peekByte() & 0x0f;
} |
Peek at the next token in the underlying stream without consuming it.
| BinaryXmlPullParser::peekNextToken | java | Reginer/aosp-android-jar | android-35/src/com/android/modules/utils/BinaryXmlPullParser.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/modules/utils/BinaryXmlPullParser.java | MIT |
private void consumeToken() throws IOException, XmlPullParserException {
final int event = mIn.readByte();
final int token = event & 0x0f;
final int type = event & 0xf0;
switch (token) {
case ATTRIBUTE: {
final Attribute attr = obtainAttribute();
attr.name = mIn.readInternedUTF();
attr.type = type;
switch (type) {
case TYPE_NULL:
case TYPE_BOOLEAN_TRUE:
case TYPE_BOOLEAN_FALSE:
// Nothing extra to fill in
break;
case TYPE_STRING:
attr.valueString = mIn.readUTF();
break;
case TYPE_STRING_INTERNED:
attr.valueString = mIn.readInternedUTF();
break;
case TYPE_BYTES_HEX:
case TYPE_BYTES_BASE64:
final int len = mIn.readUnsignedShort();
final byte[] res = new byte[len];
mIn.readFully(res);
attr.valueBytes = res;
break;
case TYPE_INT:
case TYPE_INT_HEX:
attr.valueInt = mIn.readInt();
break;
case TYPE_LONG:
case TYPE_LONG_HEX:
attr.valueLong = mIn.readLong();
break;
case TYPE_FLOAT:
attr.valueFloat = mIn.readFloat();
break;
case TYPE_DOUBLE:
attr.valueDouble = mIn.readDouble();
break;
default:
throw new IOException("Unexpected data type " + type);
}
break;
}
case XmlPullParser.START_DOCUMENT: {
mCurrentName = null;
mCurrentText = null;
if (mAttributeCount > 0) resetAttributes();
break;
}
case XmlPullParser.END_DOCUMENT: {
mCurrentName = null;
mCurrentText = null;
if (mAttributeCount > 0) resetAttributes();
break;
}
case XmlPullParser.START_TAG: {
mCurrentName = mIn.readInternedUTF();
mCurrentText = null;
if (mAttributeCount > 0) resetAttributes();
break;
}
case XmlPullParser.END_TAG: {
mCurrentName = mIn.readInternedUTF();
mCurrentText = null;
if (mAttributeCount > 0) resetAttributes();
break;
}
case XmlPullParser.TEXT:
case XmlPullParser.CDSECT:
case XmlPullParser.PROCESSING_INSTRUCTION:
case XmlPullParser.COMMENT:
case XmlPullParser.DOCDECL:
case XmlPullParser.IGNORABLE_WHITESPACE: {
mCurrentName = null;
mCurrentText = mIn.readUTF();
if (mAttributeCount > 0) resetAttributes();
break;
}
case XmlPullParser.ENTITY_REF: {
mCurrentName = mIn.readUTF();
mCurrentText = resolveEntity(mCurrentName);
if (mAttributeCount > 0) resetAttributes();
break;
}
default: {
throw new IOException("Unknown token " + token + " with type " + type);
}
}
} |
Parse and consume the next token in the underlying stream.
| BinaryXmlPullParser::consumeToken | java | Reginer/aosp-android-jar | android-35/src/com/android/modules/utils/BinaryXmlPullParser.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/modules/utils/BinaryXmlPullParser.java | MIT |
private void consumeAdditionalText() throws IOException, XmlPullParserException {
String combinedText = mCurrentText;
while (true) {
final int token = peekNextExternalToken();
switch (token) {
case COMMENT:
case PROCESSING_INSTRUCTION:
// Quietly consumed
consumeToken();
break;
case TEXT:
case CDSECT:
case ENTITY_REF:
// Additional text regions collected
consumeToken();
combinedText += mCurrentText;
break;
default:
// Next token is something non-text, so wrap things up
mCurrentToken = TEXT;
mCurrentName = null;
mCurrentText = combinedText;
return;
}
}
} |
When the current tag is {@link #TEXT}, consume all subsequent "text"
events, as described by {@link #next}. When finished, the current event
will still be {@link #TEXT}.
| BinaryXmlPullParser::consumeAdditionalText | java | Reginer/aosp-android-jar | android-35/src/com/android/modules/utils/BinaryXmlPullParser.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/modules/utils/BinaryXmlPullParser.java | MIT |
private @NonNull Attribute obtainAttribute() {
if (mAttributeCount == mAttributes.length) {
final int before = mAttributes.length;
final int after = before + (before >> 1);
mAttributes = Arrays.copyOf(mAttributes, after);
for (int i = before; i < after; i++) {
mAttributes[i] = new Attribute();
}
}
return mAttributes[mAttributeCount++];
} |
Allocate and return a new {@link Attribute} associated with the tag being
currently processed. This will automatically grow the internal pool as
needed.
| BinaryXmlPullParser::obtainAttribute | java | Reginer/aosp-android-jar | android-35/src/com/android/modules/utils/BinaryXmlPullParser.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/modules/utils/BinaryXmlPullParser.java | MIT |
private void resetAttributes() {
for (int i = 0; i < mAttributeCount; i++) {
mAttributes[i].reset();
}
mAttributeCount = 0;
} |
Clear any {@link Attribute} instances that have been allocated by
{@link #obtainAttribute()}, returning them into the pool for recycling.
| BinaryXmlPullParser::resetAttributes | java | Reginer/aosp-android-jar | android-35/src/com/android/modules/utils/BinaryXmlPullParser.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/modules/utils/BinaryXmlPullParser.java | MIT |
public Key(String name, String fallbackName, Class<T> type) {
mKey = new CameraMetadataNative.Key<T>(name, fallbackName, type);
} |
Visible for testing and vendor extensions only.
@hide
| Key::Key | java | Reginer/aosp-android-jar | android-35/src/android/hardware/camera2/CameraCharacteristics.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/android/hardware/camera2/CameraCharacteristics.java | MIT |
public Key(@NonNull String name, @NonNull Class<T> type) {
mKey = new CameraMetadataNative.Key<T>(name, type);
} |
Construct a new Key with a given name and type.
<p>Normally, applications should use the existing Key definitions in
{@link CameraCharacteristics}, and not need to construct their own Key objects. However,
they may be useful for testing purposes and for defining custom camera
characteristics.</p>
| Key::Key | java | Reginer/aosp-android-jar | android-35/src/android/hardware/camera2/CameraCharacteristics.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/android/hardware/camera2/CameraCharacteristics.java | MIT |
public long getVendorId() {
return mKey.getVendorId();
} |
Return vendor tag id.
@hide
| Key::getVendorId | java | Reginer/aosp-android-jar | android-35/src/android/hardware/camera2/CameraCharacteristics.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/android/hardware/camera2/CameraCharacteristics.java | MIT |
public CameraCharacteristics(CameraMetadataNative properties) {
mProperties = CameraMetadataNative.move(properties);
setNativeInstance(mProperties);
} |
Takes ownership of the passed-in properties object
@param properties Camera properties.
@hide
| CameraCharacteristics::CameraCharacteristics | java | Reginer/aosp-android-jar | android-35/src/android/hardware/camera2/CameraCharacteristics.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/android/hardware/camera2/CameraCharacteristics.java | MIT |
public CameraMetadataNative getNativeCopy() {
return new CameraMetadataNative(mProperties);
} |
Returns a copy of the underlying {@link CameraMetadataNative}.
@hide
| CameraCharacteristics::getNativeCopy | java | Reginer/aosp-android-jar | android-35/src/android/hardware/camera2/CameraCharacteristics.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/android/hardware/camera2/CameraCharacteristics.java | MIT |
CameraManager.DeviceStateListener getDeviceStateListener() {
if (mFoldStateListener == null) {
mFoldStateListener = new CameraManager.DeviceStateListener() {
@Override
public final void onDeviceStateChanged(boolean folded) {
synchronized (mLock) {
mFoldedDeviceState = folded;
}
}};
}
return mFoldStateListener;
} |
Return the device state listener for this Camera characteristics instance
| CameraCharacteristics::getDeviceStateListener | java | Reginer/aosp-android-jar | android-35/src/android/hardware/camera2/CameraCharacteristics.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/android/hardware/camera2/CameraCharacteristics.java | MIT |
private String processLine(String line, ArrayList<String> tags) {
line = line.trim();
int removedCharacterCount = 0;
StringBuilder processedLine = new StringBuilder(line);
Matcher matcher = SUBRIP_TAG_PATTERN.matcher(line);
while (matcher.find()) {
String tag = matcher.group();
tags.add(tag);
int start = matcher.start() - removedCharacterCount;
int tagLength = tag.length();
processedLine.replace(start, /* end= */ start + tagLength, /* str= */ "");
removedCharacterCount += tagLength;
}
return processedLine.toString();
} |
Trims and removes tags from the given line. The removed tags are added to {@code tags}.
@param line The line to process.
@param tags A list to which removed tags will be added.
@return The processed line.
| SubripDecoder::processLine | java | Reginer/aosp-android-jar | android-34/src/com/google/android/exoplayer2/text/subrip/SubripDecoder.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-34/src/com/google/android/exoplayer2/text/subrip/SubripDecoder.java | MIT |
private Cue buildCue(Spanned text, @Nullable String alignmentTag) {
Cue.Builder cue = new Cue.Builder().setText(text);
if (alignmentTag == null) {
return cue.build();
}
// Horizontal alignment.
switch (alignmentTag) {
case ALIGN_BOTTOM_LEFT:
case ALIGN_MID_LEFT:
case ALIGN_TOP_LEFT:
cue.setPositionAnchor(Cue.ANCHOR_TYPE_START);
break;
case ALIGN_BOTTOM_RIGHT:
case ALIGN_MID_RIGHT:
case ALIGN_TOP_RIGHT:
cue.setPositionAnchor(Cue.ANCHOR_TYPE_END);
break;
case ALIGN_BOTTOM_MID:
case ALIGN_MID_MID:
case ALIGN_TOP_MID:
default:
cue.setPositionAnchor(Cue.ANCHOR_TYPE_MIDDLE);
break;
}
// Vertical alignment.
switch (alignmentTag) {
case ALIGN_BOTTOM_LEFT:
case ALIGN_BOTTOM_MID:
case ALIGN_BOTTOM_RIGHT:
cue.setLineAnchor(Cue.ANCHOR_TYPE_END);
break;
case ALIGN_TOP_LEFT:
case ALIGN_TOP_MID:
case ALIGN_TOP_RIGHT:
cue.setLineAnchor(Cue.ANCHOR_TYPE_START);
break;
case ALIGN_MID_LEFT:
case ALIGN_MID_MID:
case ALIGN_MID_RIGHT:
default:
cue.setLineAnchor(Cue.ANCHOR_TYPE_MIDDLE);
break;
}
return cue.setPosition(getFractionalPositionForAnchorType(cue.getPositionAnchor()))
.setLine(getFractionalPositionForAnchorType(cue.getLineAnchor()), Cue.LINE_TYPE_FRACTION)
.build();
} |
Build a {@link Cue} based on the given text and alignment tag.
@param text The text.
@param alignmentTag The alignment tag, or {@code null} if no alignment tag is available.
@return Built cue
| SubripDecoder::buildCue | java | Reginer/aosp-android-jar | android-34/src/com/google/android/exoplayer2/text/subrip/SubripDecoder.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-34/src/com/google/android/exoplayer2/text/subrip/SubripDecoder.java | MIT |
public NormalCallDomainSelectionConnection(@NonNull Phone phone,
@NonNull DomainSelectionController controller) {
super(phone, SELECTOR_TYPE_CALLING, false, controller);
mTag = "NormalCallDomainSelectionConnection";
} |
Create an instance.
@param phone For which this service is requested.
@param controller The controller to communicate with the domain selection service.
| NormalCallDomainSelectionConnection::NormalCallDomainSelectionConnection | java | Reginer/aosp-android-jar | android-35/src/com/android/internal/telephony/domainselection/NormalCallDomainSelectionConnection.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/internal/telephony/domainselection/NormalCallDomainSelectionConnection.java | MIT |
public CompletableFuture<Integer> createNormalConnection(
@NonNull DomainSelectionService.SelectionAttributes attr,
@NonNull DomainSelectionConnectionCallback callback) {
mCallback = callback;
selectDomain(attr);
return getCompletableFuture();
} |
Request a domain for normal call.
@param attr The attributes required to determine the domain.
@param callback A callback to receive the response.
@return A {@link CompletableFuture} callback to receive the result.
| NormalCallDomainSelectionConnection::createNormalConnection | java | Reginer/aosp-android-jar | android-35/src/com/android/internal/telephony/domainselection/NormalCallDomainSelectionConnection.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/internal/telephony/domainselection/NormalCallDomainSelectionConnection.java | MIT |
public static @NonNull DomainSelectionService.SelectionAttributes getSelectionAttributes(
int slotId, int subId, @NonNull String callId, @NonNull String number,
boolean isVideoCall, int callFailCause, @Nullable ImsReasonInfo imsReasonInfo) {
DomainSelectionService.SelectionAttributes.Builder builder =
new DomainSelectionService.SelectionAttributes.Builder(
slotId, subId, SELECTOR_TYPE_CALLING)
.setEmergency(false)
.setCallId(callId)
.setAddress(Uri.fromParts(PhoneAccount.SCHEME_TEL, number, null))
.setCsDisconnectCause(callFailCause)
.setVideoCall(isVideoCall);
if (imsReasonInfo != null) {
builder.setPsDisconnectCause(imsReasonInfo);
}
return builder.build();
} |
Returns the attributes required to determine the domain for a normal call.
@param slotId The slot identifier.
@param subId The subscription identifier.
@param callId The call identifier.
@param number The dialed number.
@param isVideoCall flag for video call.
@param callFailCause The reason why the last CS attempt failed.
@param imsReasonInfo The reason why the last PS attempt failed.
@return The attributes required to determine the domain.
| NormalCallDomainSelectionConnection::getSelectionAttributes | java | Reginer/aosp-android-jar | android-35/src/com/android/internal/telephony/domainselection/NormalCallDomainSelectionConnection.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/internal/telephony/domainselection/NormalCallDomainSelectionConnection.java | MIT |
default boolean canAddInternalSystemWindow() {
return false;
} |
Returns true if the window owner can add internal system windows.
That is, they have {@link Manifest.permission#INTERNAL_SYSTEM_WINDOW}.
| canAddInternalSystemWindow | java | Reginer/aosp-android-jar | android-35/src/com/android/server/policy/WindowManagerPolicy.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/server/policy/WindowManagerPolicy.java | MIT |
static String lidStateToString(int lid) {
switch (lid) {
case LID_ABSENT:
return "LID_ABSENT";
case LID_CLOSED:
return "LID_CLOSED";
case LID_OPEN:
return "LID_OPEN";
default:
return Integer.toString(lid);
}
} |
Convert the lid state to a human readable format.
| lidStateToString | java | Reginer/aosp-android-jar | android-35/src/com/android/server/policy/WindowManagerPolicy.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/server/policy/WindowManagerPolicy.java | MIT |
static String cameraLensStateToString(int lens) {
switch (lens) {
case CAMERA_LENS_COVER_ABSENT:
return "CAMERA_LENS_COVER_ABSENT";
case CAMERA_LENS_UNCOVERED:
return "CAMERA_LENS_UNCOVERED";
case CAMERA_LENS_COVERED:
return "CAMERA_LENS_COVERED";
default:
return Integer.toString(lens);
}
} |
Convert the camera lens state to a human readable format.
| cameraLensStateToString | java | Reginer/aosp-android-jar | android-35/src/com/android/server/policy/WindowManagerPolicy.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/server/policy/WindowManagerPolicy.java | MIT |
default int getWindowLayerLw(WindowState win) {
return getWindowLayerFromTypeLw(win.getBaseType(), win.canAddInternalSystemWindow());
} |
Returns the layer assignment for the window state. Allows you to control how different
kinds of windows are ordered on-screen.
@param win The window state
@return int An arbitrary integer used to order windows, with lower numbers below higher ones.
| getWindowLayerLw | java | Reginer/aosp-android-jar | android-35/src/com/android/server/policy/WindowManagerPolicy.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/server/policy/WindowManagerPolicy.java | MIT |
default int getWindowLayerFromTypeLw(int type) {
if (isSystemAlertWindowType(type)) {
throw new IllegalArgumentException("Use getWindowLayerFromTypeLw() or"
+ " getWindowLayerLw() for alert window types");
}
return getWindowLayerFromTypeLw(type, false /* canAddInternalSystemWindow */);
} |
Returns the layer assignment for the window type. Allows you to control how different
kinds of windows are ordered on-screen.
@param type The type of window being assigned.
@return int An arbitrary integer used to order windows, with lower numbers below higher ones.
| getWindowLayerFromTypeLw | java | Reginer/aosp-android-jar | android-35/src/com/android/server/policy/WindowManagerPolicy.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/server/policy/WindowManagerPolicy.java | MIT |
default int getWindowLayerFromTypeLw(int type, boolean canAddInternalSystemWindow) {
return getWindowLayerFromTypeLw(type, canAddInternalSystemWindow,
false /* roundedCornerOverlay */);
} |
Returns the layer assignment for the window type. Allows you to control how different
kinds of windows are ordered on-screen.
@param type The type of window being assigned.
@param canAddInternalSystemWindow If the owner window associated with the type we are
evaluating can add internal system windows. I.e they have
{@link Manifest.permission#INTERNAL_SYSTEM_WINDOW}. If true, alert window
types {@link android.view.WindowManager.LayoutParams#isSystemAlertWindowType(int)}
can be assigned layers greater than the layer for
{@link android.view.WindowManager.LayoutParams#TYPE_APPLICATION_OVERLAY} Else, their
layers would be lesser.
@return int An arbitrary integer used to order windows, with lower numbers below higher ones.
| getWindowLayerFromTypeLw | java | Reginer/aosp-android-jar | android-35/src/com/android/server/policy/WindowManagerPolicy.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/server/policy/WindowManagerPolicy.java | MIT |
default int getWindowLayerFromTypeLw(int type, boolean canAddInternalSystemWindow,
boolean roundedCornerOverlay) {
// Always put the rounded corner layer to the top most.
if (roundedCornerOverlay && canAddInternalSystemWindow) {
return getMaxWindowLayer();
}
if (type >= FIRST_APPLICATION_WINDOW && type <= LAST_APPLICATION_WINDOW) {
return APPLICATION_LAYER;
}
switch (type) {
case TYPE_WALLPAPER:
// wallpaper is at the bottom, though the window manager may move it.
return 1;
case TYPE_PRESENTATION:
case TYPE_PRIVATE_PRESENTATION:
case TYPE_DOCK_DIVIDER:
case TYPE_QS_DIALOG:
case TYPE_PHONE:
return 3;
case TYPE_SEARCH_BAR:
return 4;
case TYPE_INPUT_CONSUMER:
return 5;
case TYPE_SYSTEM_DIALOG:
return 6;
case TYPE_TOAST:
// toasts and the plugged-in battery thing
return 7;
case TYPE_PRIORITY_PHONE:
// SIM errors and unlock. Not sure if this really should be in a high layer.
return 8;
case TYPE_SYSTEM_ALERT:
// like the ANR / app crashed dialogs
// Type is deprecated for non-system apps. For system apps, this type should be
// in a higher layer than TYPE_APPLICATION_OVERLAY.
return canAddInternalSystemWindow ? 12 : 9;
case TYPE_APPLICATION_OVERLAY:
return 11;
case TYPE_INPUT_METHOD:
// on-screen keyboards and other such input method user interfaces go here.
return 13;
case TYPE_INPUT_METHOD_DIALOG:
// on-screen keyboards and other such input method user interfaces go here.
return 14;
case TYPE_STATUS_BAR:
return 15;
case TYPE_STATUS_BAR_ADDITIONAL:
return 16;
case TYPE_NOTIFICATION_SHADE:
return 17;
case TYPE_STATUS_BAR_SUB_PANEL:
return 18;
case TYPE_KEYGUARD_DIALOG:
return 19;
case TYPE_VOICE_INTERACTION_STARTING:
return 20;
case TYPE_VOICE_INTERACTION:
// voice interaction layer should show above the lock screen.
return 21;
case TYPE_VOLUME_OVERLAY:
// the on-screen volume indicator and controller shown when the user
// changes the device volume
return 22;
case TYPE_SYSTEM_OVERLAY:
// the on-screen volume indicator and controller shown when the user
// changes the device volume
return canAddInternalSystemWindow ? 23 : 10;
case TYPE_NAVIGATION_BAR:
// the navigation bar, if available, shows atop most things
return 24;
case TYPE_NAVIGATION_BAR_PANEL:
// some panels (e.g. search) need to show on top of the navigation bar
return 25;
case TYPE_SCREENSHOT:
// screenshot selection layer shouldn't go above system error, but it should cover
// navigation bars at the very least.
return 26;
case TYPE_SYSTEM_ERROR:
// system-level error dialogs
return canAddInternalSystemWindow ? 27 : 9;
case TYPE_MAGNIFICATION_OVERLAY:
// used to highlight the magnified portion of a display
return 28;
case TYPE_DISPLAY_OVERLAY:
// used to simulate secondary display devices
return 29;
case TYPE_DRAG:
// the drag layer: input for drag-and-drop is associated with this window,
// which sits above all other focusable windows
return 30;
case TYPE_ACCESSIBILITY_OVERLAY:
// overlay put by accessibility services to intercept user interaction
return 31;
case TYPE_ACCESSIBILITY_MAGNIFICATION_OVERLAY:
return 32;
case TYPE_SECURE_SYSTEM_OVERLAY:
return 33;
case TYPE_BOOT_PROGRESS:
return 34;
case TYPE_POINTER:
// the (mouse) pointer layer
return 35;
default:
Slog.e("WindowManager", "Unknown window type: " + type);
return 3;
}
} |
Returns the layer assignment for the window type. Allows you to control how different
kinds of windows are ordered on-screen.
@param type The type of window being assigned.
@param canAddInternalSystemWindow If the owner window associated with the type we are
evaluating can add internal system windows. I.e they have
{@link Manifest.permission#INTERNAL_SYSTEM_WINDOW}. If true, alert window
types {@link android.view.WindowManager.LayoutParams#isSystemAlertWindowType(int)}
can be assigned layers greater than the layer for
{@link android.view.WindowManager.LayoutParams#TYPE_APPLICATION_OVERLAY} Else, their
layers would be lesser.
@param roundedCornerOverlay {#code true} to indicate that the owner window is rounded corner
overlay.
@return int An arbitrary integer used to order windows, with lower numbers below higher ones.
| getWindowLayerFromTypeLw | java | Reginer/aosp-android-jar | android-35/src/com/android/server/policy/WindowManagerPolicy.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/server/policy/WindowManagerPolicy.java | MIT |
default int getMaxWindowLayer() {
return 36;
} |
Returns the max window layer.
<p>Note that the max window layer should be higher that the maximum value which reported
by {@link #getWindowLayerFromTypeLw(int, boolean)} to contain rounded corner overlay.</p>
@see WindowManager.LayoutParams#PRIVATE_FLAG_IS_ROUNDED_CORNERS_OVERLAY
| getMaxWindowLayer | java | Reginer/aosp-android-jar | android-35/src/com/android/server/policy/WindowManagerPolicy.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/server/policy/WindowManagerPolicy.java | MIT |
default int getSubWindowLayerFromTypeLw(int type) {
switch (type) {
case TYPE_APPLICATION_PANEL:
case TYPE_APPLICATION_ATTACHED_DIALOG:
return APPLICATION_PANEL_SUBLAYER;
case TYPE_APPLICATION_MEDIA:
return APPLICATION_MEDIA_SUBLAYER;
case TYPE_APPLICATION_MEDIA_OVERLAY:
return APPLICATION_MEDIA_OVERLAY_SUBLAYER;
case TYPE_APPLICATION_SUB_PANEL:
return APPLICATION_SUB_PANEL_SUBLAYER;
case TYPE_APPLICATION_ABOVE_SUB_PANEL:
return APPLICATION_ABOVE_SUB_PANEL_SUBLAYER;
}
Slog.e("WindowManager", "Unknown sub-window type: " + type);
return 0;
} |
Return how to Z-order sub-windows in relation to the window they are attached to.
Return positive to have them ordered in front, negative for behind.
@param type The sub-window type code.
@return int Layer in relation to the attached window, where positive is
above and negative is below.
| getSubWindowLayerFromTypeLw | java | Reginer/aosp-android-jar | android-35/src/com/android/server/policy/WindowManagerPolicy.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/server/policy/WindowManagerPolicy.java | MIT |
default boolean isKeyguardUnoccluding() {
return false;
} |
Return whether the keyguard is unoccluding.
@return {@code true} if the keyguard is unoccluding.
| isKeyguardUnoccluding | java | Reginer/aosp-android-jar | android-35/src/com/android/server/policy/WindowManagerPolicy.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/server/policy/WindowManagerPolicy.java | MIT |
default void setDismissImeOnBackKeyPressed(boolean newValue) {
// Default implementation does nothing.
} |
An internal callback (from InputMethodManagerService) to notify a state change regarding
whether the back key should dismiss the software keyboard (IME) or not.
@param newValue {@code true} if the software keyboard is shown and the back key is expected
to dismiss the software keyboard.
@hide
| setDismissImeOnBackKeyPressed | java | Reginer/aosp-android-jar | android-35/src/com/android/server/policy/WindowManagerPolicy.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/server/policy/WindowManagerPolicy.java | MIT |
static String userRotationModeToString(int mode) {
switch(mode) {
case USER_ROTATION_FREE:
return "USER_ROTATION_FREE";
case USER_ROTATION_LOCKED:
return "USER_ROTATION_LOCKED";
default:
return Integer.toString(mode);
}
} |
Convert the user rotation mode to a human readable format.
| userRotationModeToString | java | Reginer/aosp-android-jar | android-35/src/com/android/server/policy/WindowManagerPolicy.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/server/policy/WindowManagerPolicy.java | MIT |
default void registerDisplayFoldListener(IDisplayFoldListener listener) {} |
Registers an IDisplayFoldListener.
| registerDisplayFoldListener | java | Reginer/aosp-android-jar | android-35/src/com/android/server/policy/WindowManagerPolicy.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/server/policy/WindowManagerPolicy.java | MIT |
default void unregisterDisplayFoldListener(IDisplayFoldListener listener) {} |
Unregisters an IDisplayFoldListener.
| unregisterDisplayFoldListener | java | Reginer/aosp-android-jar | android-35/src/com/android/server/policy/WindowManagerPolicy.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/server/policy/WindowManagerPolicy.java | MIT |
default void setOverrideFoldedArea(@NonNull Rect area) {} |
Overrides the folded area.
@param area the overriding folded area or an empty {@code Rect} to clear the override.
| setOverrideFoldedArea | java | Reginer/aosp-android-jar | android-35/src/com/android/server/policy/WindowManagerPolicy.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/server/policy/WindowManagerPolicy.java | MIT |
default @NonNull Rect getFoldedArea() {
return new Rect();
} |
Get the display folded area.
| getFoldedArea | java | Reginer/aosp-android-jar | android-35/src/com/android/server/policy/WindowManagerPolicy.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/server/policy/WindowManagerPolicy.java | MIT |
default void onDefaultDisplayFocusChangedLw(WindowState newFocus) {} |
A new window on default display has been focused.
| onDefaultDisplayFocusChangedLw | java | Reginer/aosp-android-jar | android-35/src/com/android/server/policy/WindowManagerPolicy.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/server/policy/WindowManagerPolicy.java | MIT |
private StreamTokenizer() {
wordChars('a', 'z');
wordChars('A', 'Z');
wordChars(128 + 32, 255);
whitespaceChars(0, ' ');
commentChar('/');
quoteChar('"');
quoteChar('\'');
parseNumbers();
} |
If the current token is a number, this field contains the value
of that number. The current token is a number when the value of
the {@code ttype} field is {@code TT_NUMBER}.
<p>
The initial value of this field is 0.0.
@see java.io.StreamTokenizer#TT_NUMBER
@see java.io.StreamTokenizer#ttype
public double nval;
/** Private constructor that initializes everything except the streams. | StreamTokenizer::StreamTokenizer | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public StreamTokenizer(Reader r) {
this();
if (r == null) {
throw new NullPointerException();
}
reader = r;
} |
Create a tokenizer that parses the given character stream.
@param r a Reader object providing the input stream.
@since JDK1.1
| StreamTokenizer::StreamTokenizer | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public void resetSyntax() {
for (int i = ctype.length; --i >= 0;)
ctype[i] = 0;
} |
Resets this tokenizer's syntax table so that all characters are
"ordinary." See the {@code ordinaryChar} method
for more information on a character being ordinary.
@see java.io.StreamTokenizer#ordinaryChar(int)
| StreamTokenizer::resetSyntax | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public void wordChars(int low, int hi) {
if (low < 0)
low = 0;
if (hi >= ctype.length)
hi = ctype.length - 1;
while (low <= hi)
ctype[low++] |= CT_ALPHA;
} |
Specifies that all characters <i>c</i> in the range
<code>low <= <i>c</i> <= high</code>
are word constituents. A word token consists of a word constituent
followed by zero or more word constituents or number constituents.
@param low the low end of the range.
@param hi the high end of the range.
| StreamTokenizer::wordChars | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public void whitespaceChars(int low, int hi) {
if (low < 0)
low = 0;
if (hi >= ctype.length)
hi = ctype.length - 1;
while (low <= hi)
ctype[low++] = CT_WHITESPACE;
} |
Specifies that all characters <i>c</i> in the range
<code>low <= <i>c</i> <= high</code>
are white space characters. White space characters serve only to
separate tokens in the input stream.
<p>Any other attribute settings for the characters in the specified
range are cleared.
@param low the low end of the range.
@param hi the high end of the range.
| StreamTokenizer::whitespaceChars | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public void ordinaryChars(int low, int hi) {
if (low < 0)
low = 0;
if (hi >= ctype.length)
hi = ctype.length - 1;
while (low <= hi)
ctype[low++] = 0;
} |
Specifies that all characters <i>c</i> in the range
<code>low <= <i>c</i> <= high</code>
are "ordinary" in this tokenizer. See the
{@code ordinaryChar} method for more information on a
character being ordinary.
@param low the low end of the range.
@param hi the high end of the range.
@see java.io.StreamTokenizer#ordinaryChar(int)
| StreamTokenizer::ordinaryChars | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public void ordinaryChar(int ch) {
if (ch >= 0 && ch < ctype.length)
ctype[ch] = 0;
} |
Specifies that the character argument is "ordinary"
in this tokenizer. It removes any special significance the
character has as a comment character, word component, string
delimiter, white space, or number character. When such a character
is encountered by the parser, the parser treats it as a
single-character token and sets {@code ttype} field to the
character value.
<p>Making a line terminator character "ordinary" may interfere
with the ability of a {@code StreamTokenizer} to count
lines. The {@code lineno} method may no longer reflect
the presence of such terminator characters in its line count.
@param ch the character.
@see java.io.StreamTokenizer#ttype
| StreamTokenizer::ordinaryChar | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public void commentChar(int ch) {
if (ch >= 0 && ch < ctype.length)
ctype[ch] = CT_COMMENT;
} |
Specified that the character argument starts a single-line
comment. All characters from the comment character to the end of
the line are ignored by this stream tokenizer.
<p>Any other attribute settings for the specified character are cleared.
@param ch the character.
| StreamTokenizer::commentChar | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public void quoteChar(int ch) {
if (ch >= 0 && ch < ctype.length)
ctype[ch] = CT_QUOTE;
} |
Specifies that matching pairs of this character delimit string
constants in this tokenizer.
<p>
When the {@code nextToken} method encounters a string
constant, the {@code ttype} field is set to the string
delimiter and the {@code sval} field is set to the body of
the string.
<p>
If a string quote character is encountered, then a string is
recognized, consisting of all characters after (but not including)
the string quote character, up to (but not including) the next
occurrence of that same string quote character, or a line
terminator, or end of file. The usual escape sequences such as
{@code "\u005Cn"} and {@code "\u005Ct"} are recognized and
converted to single characters as the string is parsed.
<p>Any other attribute settings for the specified character are cleared.
@param ch the character.
@see java.io.StreamTokenizer#nextToken()
@see java.io.StreamTokenizer#sval
@see java.io.StreamTokenizer#ttype
| StreamTokenizer::quoteChar | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public void parseNumbers() {
for (int i = '0'; i <= '9'; i++)
ctype[i] |= CT_DIGIT;
ctype['.'] |= CT_DIGIT;
ctype['-'] |= CT_DIGIT;
} |
Specifies that numbers should be parsed by this tokenizer. The
syntax table of this tokenizer is modified so that each of the twelve
characters:
<blockquote><pre>
0 1 2 3 4 5 6 7 8 9 . -
</pre></blockquote>
<p>
has the "numeric" attribute.
<p>
When the parser encounters a word token that has the format of a
double precision floating-point number, it treats the token as a
number rather than a word, by setting the {@code ttype}
field to the value {@code TT_NUMBER} and putting the numeric
value of the token into the {@code nval} field.
@see java.io.StreamTokenizer#nval
@see java.io.StreamTokenizer#TT_NUMBER
@see java.io.StreamTokenizer#ttype
| StreamTokenizer::parseNumbers | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public void eolIsSignificant(boolean flag) {
eolIsSignificantP = flag;
} |
Determines whether or not ends of line are treated as tokens.
If the flag argument is true, this tokenizer treats end of lines
as tokens; the {@code nextToken} method returns
{@code TT_EOL} and also sets the {@code ttype} field to
this value when an end of line is read.
<p>
A line is a sequence of characters ending with either a
carriage-return character ({@code '\u005Cr'}) or a newline
character ({@code '\u005Cn'}). In addition, a carriage-return
character followed immediately by a newline character is treated
as a single end-of-line token.
<p>
If the {@code flag} is false, end-of-line characters are
treated as white space and serve only to separate tokens.
@param flag {@code true} indicates that end-of-line characters
are separate tokens; {@code false} indicates that
end-of-line characters are white space.
@see java.io.StreamTokenizer#nextToken()
@see java.io.StreamTokenizer#ttype
@see java.io.StreamTokenizer#TT_EOL
| StreamTokenizer::eolIsSignificant | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public void slashStarComments(boolean flag) {
slashStarCommentsP = flag;
} |
Determines whether or not the tokenizer recognizes C-style comments.
If the flag argument is {@code true}, this stream tokenizer
recognizes C-style comments. All text between successive
occurrences of {@code /*} and <code>*/</code> are discarded.
<p>
If the flag argument is {@code false}, then C-style comments
are not treated specially.
@param flag {@code true} indicates to recognize and ignore
C-style comments.
| StreamTokenizer::slashStarComments | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public void slashSlashComments(boolean flag) {
slashSlashCommentsP = flag;
} |
Determines whether or not the tokenizer recognizes C++-style comments.
If the flag argument is {@code true}, this stream tokenizer
recognizes C++-style comments. Any occurrence of two consecutive
slash characters ({@code '/'}) is treated as the beginning of
a comment that extends to the end of the line.
<p>
If the flag argument is {@code false}, then C++-style
comments are not treated specially.
@param flag {@code true} indicates to recognize and ignore
C++-style comments.
| StreamTokenizer::slashSlashComments | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public void lowerCaseMode(boolean fl) {
forceLower = fl;
} |
Determines whether or not word token are automatically lowercased.
If the flag argument is {@code true}, then the value in the
{@code sval} field is lowercased whenever a word token is
returned (the {@code ttype} field has the
value {@code TT_WORD} by the {@code nextToken} method
of this tokenizer.
<p>
If the flag argument is {@code false}, then the
{@code sval} field is not modified.
@param fl {@code true} indicates that all word tokens should
be lowercased.
@see java.io.StreamTokenizer#nextToken()
@see java.io.StreamTokenizer#ttype
@see java.io.StreamTokenizer#TT_WORD
| StreamTokenizer::lowerCaseMode | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
private int read() throws IOException {
if (reader != null)
return reader.read();
else if (input != null)
return input.read();
else
throw new IllegalStateException();
} |
Determines whether or not word token are automatically lowercased.
If the flag argument is {@code true}, then the value in the
{@code sval} field is lowercased whenever a word token is
returned (the {@code ttype} field has the
value {@code TT_WORD} by the {@code nextToken} method
of this tokenizer.
<p>
If the flag argument is {@code false}, then the
{@code sval} field is not modified.
@param fl {@code true} indicates that all word tokens should
be lowercased.
@see java.io.StreamTokenizer#nextToken()
@see java.io.StreamTokenizer#ttype
@see java.io.StreamTokenizer#TT_WORD
public void lowerCaseMode(boolean fl) {
forceLower = fl;
}
/** Read the next character | StreamTokenizer::read | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public int nextToken() throws IOException {
if (pushedBack) {
pushedBack = false;
return ttype;
}
byte ct[] = ctype;
sval = null;
int c = peekc;
if (c < 0)
c = NEED_CHAR;
if (c == SKIP_LF) {
c = read();
if (c < 0)
return ttype = TT_EOF;
if (c == '\n')
c = NEED_CHAR;
}
if (c == NEED_CHAR) {
c = read();
if (c < 0)
return ttype = TT_EOF;
}
ttype = c; /* Just to be safe */
/* Set peekc so that the next invocation of nextToken will read
* another character unless peekc is reset in this invocation
*/
peekc = NEED_CHAR;
int ctype = c < 256 ? ct[c] : CT_ALPHA;
while ((ctype & CT_WHITESPACE) != 0) {
if (c == '\r') {
LINENO++;
if (eolIsSignificantP) {
peekc = SKIP_LF;
return ttype = TT_EOL;
}
c = read();
if (c == '\n')
c = read();
} else {
if (c == '\n') {
LINENO++;
if (eolIsSignificantP) {
return ttype = TT_EOL;
}
}
c = read();
}
if (c < 0)
return ttype = TT_EOF;
ctype = c < 256 ? ct[c] : CT_ALPHA;
}
if ((ctype & CT_DIGIT) != 0) {
boolean neg = false;
if (c == '-') {
c = read();
if (c != '.' && (c < '0' || c > '9')) {
peekc = c;
return ttype = '-';
}
neg = true;
}
double v = 0;
int decexp = 0;
int seendot = 0;
while (true) {
if (c == '.' && seendot == 0)
seendot = 1;
else if ('0' <= c && c <= '9') {
v = v * 10 + (c - '0');
decexp += seendot;
} else
break;
c = read();
}
peekc = c;
if (decexp != 0) {
double denom = 10;
decexp--;
while (decexp > 0) {
denom *= 10;
decexp--;
}
/* Do one division of a likely-to-be-more-accurate number */
v = v / denom;
}
nval = neg ? -v : v;
return ttype = TT_NUMBER;
}
if ((ctype & CT_ALPHA) != 0) {
int i = 0;
do {
if (i >= buf.length) {
buf = Arrays.copyOf(buf, buf.length * 2);
}
buf[i++] = (char) c;
c = read();
ctype = c < 0 ? CT_WHITESPACE : c < 256 ? ct[c] : CT_ALPHA;
} while ((ctype & (CT_ALPHA | CT_DIGIT)) != 0);
peekc = c;
sval = String.copyValueOf(buf, 0, i);
if (forceLower)
sval = sval.toLowerCase();
return ttype = TT_WORD;
}
if ((ctype & CT_QUOTE) != 0) {
ttype = c;
int i = 0;
/* Invariants (because \Octal needs a lookahead):
* (i) c contains char value
* (ii) d contains the lookahead
*/
int d = read();
while (d >= 0 && d != ttype && d != '\n' && d != '\r') {
if (d == '\\') {
c = read();
int first = c; /* To allow \377, but not \477 */
if (c >= '0' && c <= '7') {
c = c - '0';
int c2 = read();
if ('0' <= c2 && c2 <= '7') {
c = (c << 3) + (c2 - '0');
c2 = read();
if ('0' <= c2 && c2 <= '7' && first <= '3') {
c = (c << 3) + (c2 - '0');
d = read();
} else
d = c2;
} else
d = c2;
} else {
switch (c) {
case 'a':
c = 0x7;
break;
case 'b':
c = '\b';
break;
case 'f':
c = 0xC;
break;
case 'n':
c = '\n';
break;
case 'r':
c = '\r';
break;
case 't':
c = '\t';
break;
case 'v':
c = 0xB;
break;
}
d = read();
}
} else {
c = d;
d = read();
}
if (i >= buf.length) {
buf = Arrays.copyOf(buf, buf.length * 2);
}
buf[i++] = (char)c;
}
/* If we broke out of the loop because we found a matching quote
* character then arrange to read a new character next time
* around; otherwise, save the character.
*/
peekc = (d == ttype) ? NEED_CHAR : d;
sval = String.copyValueOf(buf, 0, i);
return ttype;
}
if (c == '/' && (slashSlashCommentsP || slashStarCommentsP)) {
c = read();
if (c == '*' && slashStarCommentsP) {
int prevc = 0;
while ((c = read()) != '/' || prevc != '*') {
if (c == '\r') {
LINENO++;
c = read();
if (c == '\n') {
c = read();
}
} else {
if (c == '\n') {
LINENO++;
c = read();
}
}
if (c < 0)
return ttype = TT_EOF;
prevc = c;
}
return nextToken();
} else if (c == '/' && slashSlashCommentsP) {
while ((c = read()) != '\n' && c != '\r' && c >= 0);
peekc = c;
return nextToken();
} else {
/* Now see if it is still a single line comment */
if ((ct['/'] & CT_COMMENT) != 0) {
while ((c = read()) != '\n' && c != '\r' && c >= 0);
peekc = c;
return nextToken();
} else {
peekc = c;
return ttype = '/';
}
}
}
if ((ctype & CT_COMMENT) != 0) {
while ((c = read()) != '\n' && c != '\r' && c >= 0);
peekc = c;
return nextToken();
}
return ttype = c;
} |
Parses the next token from the input stream of this tokenizer.
The type of the next token is returned in the {@code ttype}
field. Additional information about the token may be in the
{@code nval} field or the {@code sval} field of this
tokenizer.
<p>
Typical clients of this
class first set up the syntax tables and then sit in a loop
calling nextToken to parse successive tokens until TT_EOF
is returned.
@return the value of the {@code ttype} field.
@exception IOException if an I/O error occurs.
@see java.io.StreamTokenizer#nval
@see java.io.StreamTokenizer#sval
@see java.io.StreamTokenizer#ttype
| StreamTokenizer::nextToken | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public void pushBack() {
if (ttype != TT_NOTHING) /* No-op if nextToken() not called */
pushedBack = true;
} |
Causes the next call to the {@code nextToken} method of this
tokenizer to return the current value in the {@code ttype}
field, and not to modify the value in the {@code nval} or
{@code sval} field.
@see java.io.StreamTokenizer#nextToken()
@see java.io.StreamTokenizer#nval
@see java.io.StreamTokenizer#sval
@see java.io.StreamTokenizer#ttype
| StreamTokenizer::pushBack | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public int lineno() {
return LINENO;
} |
Return the current line number.
@return the current line number of this stream tokenizer.
| StreamTokenizer::lineno | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public String toString() {
String ret;
switch (ttype) {
case TT_EOF:
ret = "EOF";
break;
case TT_EOL:
ret = "EOL";
break;
case TT_WORD:
ret = sval;
break;
case TT_NUMBER:
ret = "n=" + nval;
break;
case TT_NOTHING:
ret = "NOTHING";
break;
default: {
/*
* ttype is the first character of either a quoted string or
* is an ordinary character. ttype can definitely not be less
* than 0, since those are reserved values used in the previous
* case statements
*/
if (ttype < 256 &&
((ctype[ttype] & CT_QUOTE) != 0)) {
ret = sval;
break;
}
char s[] = new char[3];
s[0] = s[2] = '\'';
s[1] = (char) ttype;
ret = new String(s);
break;
}
}
return "Token[" + ret + "], line " + LINENO;
} |
Returns the string representation of the current stream token and
the line number it occurs on.
<p>The precise string returned is unspecified, although the following
example can be considered typical:
<blockquote><pre>Token['a'], line 10</pre></blockquote>
@return a string representation of the token
@see java.io.StreamTokenizer#nval
@see java.io.StreamTokenizer#sval
@see java.io.StreamTokenizer#ttype
| StreamTokenizer::toString | java | Reginer/aosp-android-jar | android-31/src/java/io/StreamTokenizer.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-31/src/java/io/StreamTokenizer.java | MIT |
public Header(int majorVersion, int minorVersion, int patchVersion,
int width, int height, long capabilities) {
this.mMajorVersion = majorVersion;
this.mMinorVersion = minorVersion;
this.mPatchVersion = patchVersion;
this.mWidth = width;
this.mHeight = height;
this.mCapabilities = capabilities;
} |
It encodes the version of the document (following semantic versioning) as well
as the dimensions of the document in pixels.
@param majorVersion the major version of the RemoteCompose document API
@param minorVersion the minor version of the RemoteCompose document API
@param patchVersion the patch version of the RemoteCompose document API
@param width the width of the RemoteCompose document
@param height the height of the RemoteCompose document
@param capabilities bitmask field storing needed capabilities (unused for now)
| Header::Header | java | Reginer/aosp-android-jar | android-35/src/com/android/internal/widget/remotecompose/core/operations/Header.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-35/src/com/android/internal/widget/remotecompose/core/operations/Header.java | MIT |
public void logOnEnableZenModeForever() {
MetricsLogger.action(
mContext,
MetricsProto.MetricsEvent.NOTIFICATION_ZEN_MODE_TOGGLE_ON_FOREVER);
} |
User enabled DND from the QS DND dialog to last until manually turned off
| ZenModeDialogMetricsLogger::logOnEnableZenModeForever | java | Reginer/aosp-android-jar | android-34/src/com/android/settingslib/notification/ZenModeDialogMetricsLogger.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-34/src/com/android/settingslib/notification/ZenModeDialogMetricsLogger.java | MIT |
public void logOnEnableZenModeUntilAlarm() {
MetricsLogger.action(
mContext,
MetricsProto.MetricsEvent.NOTIFICATION_ZEN_MODE_TOGGLE_ON_ALARM);
} |
User enabled DND from the QS DND dialog to last until the next alarm goes off
| ZenModeDialogMetricsLogger::logOnEnableZenModeUntilAlarm | java | Reginer/aosp-android-jar | android-34/src/com/android/settingslib/notification/ZenModeDialogMetricsLogger.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-34/src/com/android/settingslib/notification/ZenModeDialogMetricsLogger.java | MIT |
public void logOnEnableZenModeUntilCountdown() {
MetricsLogger.action(
mContext,
MetricsProto.MetricsEvent.NOTIFICATION_ZEN_MODE_TOGGLE_ON_COUNTDOWN);
} |
User enabled DND from the QS DND dialog to last until countdown is done
| ZenModeDialogMetricsLogger::logOnEnableZenModeUntilCountdown | java | Reginer/aosp-android-jar | android-34/src/com/android/settingslib/notification/ZenModeDialogMetricsLogger.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-34/src/com/android/settingslib/notification/ZenModeDialogMetricsLogger.java | MIT |
public void logOnConditionSelected() {
MetricsLogger.action(
mContext,
MetricsProto.MetricsEvent.QS_DND_CONDITION_SELECT);
} |
User selected an option on the DND dialog
| ZenModeDialogMetricsLogger::logOnConditionSelected | java | Reginer/aosp-android-jar | android-34/src/com/android/settingslib/notification/ZenModeDialogMetricsLogger.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-34/src/com/android/settingslib/notification/ZenModeDialogMetricsLogger.java | MIT |
public void logOnClickTimeButton(boolean up) {
MetricsLogger.action(mContext, MetricsProto.MetricsEvent.QS_DND_TIME, up);
} |
User increased or decreased countdown duration of DND from the DND dialog
| ZenModeDialogMetricsLogger::logOnClickTimeButton | java | Reginer/aosp-android-jar | android-34/src/com/android/settingslib/notification/ZenModeDialogMetricsLogger.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-34/src/com/android/settingslib/notification/ZenModeDialogMetricsLogger.java | MIT |
public namednodemapremovenameditemns07(final DOMTestDocumentBuilderFactory factory) throws org.w3c.domts.DOMTestIncompatibleException {
org.w3c.domts.DocumentBuilderSetting[] settings =
new org.w3c.domts.DocumentBuilderSetting[] {
org.w3c.domts.DocumentBuilderSetting.namespaceAware
};
DOMTestDocumentBuilderFactory testFactory = factory.newInstance(settings);
setFactory(testFactory);
//
// check if loaded documents are supported for content type
//
String contentType = getContentType();
preload(contentType, "staffNS", true);
} |
Constructor.
@param factory document factory, may not be null
@throws org.w3c.domts.DOMTestIncompatibleException Thrown if test is not compatible with parser configuration
| namednodemapremovenameditemns07::namednodemapremovenameditemns07 | java | Reginer/aosp-android-jar | android-34/src/org/w3c/domts/level2/core/namednodemapremovenameditemns07.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-34/src/org/w3c/domts/level2/core/namednodemapremovenameditemns07.java | MIT |
public void runTest() throws Throwable {
Document doc;
NamedNodeMap attributes;
Node element;
Attr attribute;
NodeList elementList;
doc = (Document) load("staffNS", true);
elementList = doc.getElementsByTagNameNS("http://www.nist.gov", "employee");
element = elementList.item(1);
attributes = element.getAttributes();
{
boolean success = false;
try {
attribute = (Attr) attributes.removeNamedItemNS("http://www.nist.gov", "domestic");
} catch (DOMException ex) {
success = (ex.code == DOMException.NOT_FOUND_ERR);
}
assertTrue("throw_NOT_FOUND_ERR", success);
}
} |
Runs the test case.
@throws Throwable Any uncaught exception causes test to fail
| namednodemapremovenameditemns07::runTest | java | Reginer/aosp-android-jar | android-34/src/org/w3c/domts/level2/core/namednodemapremovenameditemns07.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-34/src/org/w3c/domts/level2/core/namednodemapremovenameditemns07.java | MIT |
public String getTargetURI() {
return "http://www.w3.org/2001/DOM-Test-Suite/level2/core/namednodemapremovenameditemns07";
} |
Gets URI that identifies the test.
@return uri identifier of test
| namednodemapremovenameditemns07::getTargetURI | java | Reginer/aosp-android-jar | android-34/src/org/w3c/domts/level2/core/namednodemapremovenameditemns07.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-34/src/org/w3c/domts/level2/core/namednodemapremovenameditemns07.java | MIT |
public static void main(final String[] args) {
DOMTestCase.doMain(namednodemapremovenameditemns07.class, args);
} |
Runs this test from the command line.
@param args command line arguments
| namednodemapremovenameditemns07::main | java | Reginer/aosp-android-jar | android-34/src/org/w3c/domts/level2/core/namednodemapremovenameditemns07.java | https://github.com/Reginer/aosp-android-jar/blob/master/android-34/src/org/w3c/domts/level2/core/namednodemapremovenameditemns07.java | MIT |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.