Searched refs:key (Results 101 - 125 of 304) sorted by relevance

1234567891011>>

/libcore/luni/src/test/java/tests/security/spec/
H A DEncodedKeySpec2Test.java48 // check public key encoding
50 Key key = fact.generatePublic(new X509EncodedKeySpec(encoded));
52 assertTrue("public key encodings were different",
53 isEqual(key, keys.getPublic()));
55 // check private key encoding
57 key = fact.generatePrivate(new PKCS8EncodedKeySpec(encoded));
59 assertTrue("private key encodings were different",
60 isEqual(key, keys.getPrivate()));
/libcore/ojluni/src/main/java/java/text/
H A DFormat.java188 * Each attribute key of the AttributedCharacterIterator will be of type
192 * key is also used as the attribute value.
302 * <code>string</code> and additional key/value pair <code>key</code>,
306 * @param key Key for AttributedCharacterIterator
307 * @param value Value associated with key in AttributedCharacterIterator
311 String string, AttributedCharacterIterator.Attribute key,
315 as.addAttribute(key, value);
321 * <code>iterator</code> and the additional attribute <code>key</code>
325 * @param key Ke
310 createAttributedCharacterIterator( String string, AttributedCharacterIterator.Attribute key, Object value) argument
329 createAttributedCharacterIterator( AttributedCharacterIterator iterator, AttributedCharacterIterator.Attribute key, Object value) argument
[all...]
/libcore/luni/src/main/java/libcore/icu/
H A DDateTimeFormat.java46 String key = skeleton + "\t" + icuLocale + "\t" + time.getTimeZone();
48 DateFormat formatter = CACHED_FORMATTERS.get(key);
52 CACHED_FORMATTERS.put(key, formatter);
/libcore/luni/src/main/java/libcore/net/http/
H A DResponseUtils.java77 final String key = components[0].trim().toLowerCase();
79 if (key.isEmpty() || value.isEmpty()) {
83 parameters.put(key, value);
/libcore/luni/src/test/java/org/apache/harmony/crypto/tests/javax/crypto/func/
H A DCipherPBEThread.java44 SecretKey key = skf.generateSecret(keySpec);
52 cip.init(Cipher.ENCRYPT_MODE, key, parSpec);
55 cip.init(Cipher.DECRYPT_MODE, key, parSpec);
/libcore/luni/src/test/java/org/apache/harmony/crypto/tests/support/
H A DMyKeyAgreementSpi.java45 protected Key engineDoPhase(Key key, boolean lastPhase) argument
75 protected void engineInit(Key key, SecureRandom random) argument
81 protected void engineInit(Key key, AlgorithmParameterSpec params, argument
/libcore/ojluni/src/main/java/java/nio/channels/spi/
H A DAbstractSelector.java58 * cancelled-key set and for removing a key from its channel's key set, and
143 * Retrieves this selector's cancelled-key set.
147 * @return The cancelled-key set
167 * The initial attachment for the resulting key
169 * @return A new key representing the registration of the given channel
176 * Removes the given key from its channel's key set.
181 * @param key
184 deregister(AbstractSelectionKey key) argument
[all...]
/libcore/ojluni/src/main/java/java/util/
H A DLinkedHashMap.java43 * if a key is <i>re-inserted</i> into the map. (A key <tt>k</tt> is
75 * key-value mappings are provided by the specified map's entry set iterator.
117 * the value associated with a key that is already contained in the map is not
303 * Returns the value to which the specified key is mapped,
304 * or {@code null} if this map contains no mapping for the key.
306 * <p>More formally, if this map contains a mapping from a key
307 * {@code k} to a value {@code v} such that {@code (key==null ? k==null :
308 * key.equals(k))}, then this method returns {@code v}; otherwise
312 * indicate that the map contains no mapping for the key; i
317 get(Object key) argument
341 LinkedHashMapEntry(int hash, K key, V value, HashMapEntry<K,V> next) argument
443 addEntry(int hash, K key, V value, int bucketIndex) argument
483 createEntry(int hash, K key, V value, int bucketIndex) argument
[all...]
H A DHashMap.java37 * <tt>null</tt> values and the <tt>null</tt> key. (The <tt>HashMap</tt>
48 * of key-value mappings). Thus, it's very important not to set the initial
83 * associated with a key that an instance already contains is not a
162 * The number of key-value mappings contained in this map.
311 * Returns the number of key-value mappings in this map.
313 * @return the number of key-value mappings in this map
320 * Returns <tt>true</tt> if this map contains no key-value mappings.
322 * @return <tt>true</tt> if this map contains no key-value mappings
329 * Returns the value to which the specified key is mapped,
330 * or {@code null} if this map contains no mapping for the key
345 get(Object key) argument
379 containsKey(Object key) argument
388 getEntry(Object key) argument
417 put(K key, V value) argument
463 putForCreate(K key, V value) argument
583 remove(Object key) argument
593 removeEntryForKey(Object key) argument
731 final K key; field in class:HashMap.HashMapEntry
806 addEntry(int hash, K key, V value, int bucketIndex) argument
824 createEntry(int hash, K key, V value, int bucketIndex) argument
1475 replace(K key, V oldValue, V newValue) argument
[all...]
H A DEnumMap.java48 * <p>Null keys are not permitted. Attempts to insert a null key will
50 * presence of a null key or to remove one will, however, function properly.
130 * Creates an empty enum map with the specified key type.
132 * @param keyType the class object of the key type for this enum map
142 * Creates an enum map with the same key type as the specified enum
160 * enum map's key type).
187 * Returns the number of key-value mappings in this map.
189 * @return the number of key-value mappings in this map
214 * key.
216 * @param key th
220 containsKey(Object key) argument
224 containsMapping(Object key, Object value) argument
244 get(Object key) argument
265 put(K key, V value) argument
285 remove(Object key) argument
296 removeMapping(Object key, Object value) argument
312 isValidKey(Object key) argument
739 typeCheck(K key) argument
[all...]
H A DResourceBundle.java124 * Resource bundles contain key/value pairs. The keys uniquely
127 * two key/value pairs:
158 * The getter methods all require the key as an argument and return
179 * manages its resource as a list of key/value pairs.
223 * key with the same value (as for the okKey below).
228 * public Object handleGetObject(String key) {
229 * if (key.equals("okKey")) return "Ok";
230 * if (key.equals("cancelKey")) return "Cancel";
247 * public Object handleGetObject(String key) {
249 * if (key
357 getString(String key) argument
374 getStringArray(String key) argument
391 getObject(String key) argument
674 LoaderReference(ClassLoader referent, ReferenceQueue q, CacheKey key) argument
692 BundleReference(ResourceBundle referent, ReferenceQueue q, CacheKey key) argument
1716 handleGetObject(String key) argument
1739 containsKey(String key) argument
[all...]
/libcore/ojluni/src/main/java/sun/security/ec/
H A DECPublicKeyImpl.java51 * Construct a key from its components. Used by the
61 key = ECParameters.encodePoint(w, params.getCurve());
65 * Construct a key from its encoding. Used by RSAKeyFactory.
89 return key.clone();
93 * Parse the key. Called by X509Key.
99 w = ECParameters.decodePoint(key, params.getCurve());
101 throw new InvalidKeyException("Invalid EC key", e);
103 throw new InvalidKeyException("Invalid EC key", e);
107 // return a string representation of this key for debugging
109 return "Sun EC public key, "
[all...]
/libcore/ojluni/src/main/java/sun/util/locale/
H A DLocaleExtensions.java62 private LocaleExtensions(String id, Character key, Extension value) { argument
64 this.extensionMap = Collections.singletonMap(key, value);
87 char key = LocaleUtils.toLower(ext.getKey().value());
90 if (LanguageTag.isPrivateusePrefixChar(key)) {
98 map.put(key, new Extension(key, LocaleUtils.toLowerString(value)));
116 String key = LocaleUtils.toLowerString(kwd.getKey().value());
118 ukmap.put(key, type);
143 public Extension getExtension(Character key) { argument
144 return extensionMap.get(LocaleUtils.toLower(key));
147 getExtensionValue(Character key) argument
[all...]
H A DUnicodeLocaleExtension.java53 private UnicodeLocaleExtension(String key, String value) { argument
54 super(SINGLETON, key + "-" + value);
56 keywords = Collections.singletonMap(key, value);
78 String key = keyword.getKey();
81 sb.append(LanguageTag.SEP).append(key);
H A DInternalLocaleBuilder.java132 public InternalLocaleBuilder setUnicodeLocaleKeyword(String key, String type) throws LocaleSyntaxException { argument
133 if (!UnicodeLocaleExtension.isKey(key)) {
134 throw new LocaleSyntaxException("Ill-formed Unicode locale keyword key: " + key);
137 CaseInsensitiveString cikey = new CaseInsensitiveString(key);
140 // null type is used for remove the key
168 // validate key
171 throw new LocaleSyntaxException("Ill-formed extension key: " + singleton);
175 CaseInsensitiveChar key = new CaseInsensitiveChar(singleton);
178 if (UnicodeLocaleExtension.isSingletonChar(key
[all...]
/libcore/support/src/test/java/tests/security/
H A DAlgorithmParameterSymmetricHelper.java54 Key key = generator.generateKey();
62 cipher.init(Cipher.ENCRYPT_MODE, key, parameters);
65 cipher.init(Cipher.DECRYPT_MODE, key, parameters);
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/prefs/
H A DPreferencesTest.java281 public String get(String key, String deflt) { argument
286 public boolean getBoolean(String key, boolean deflt) { argument
291 public byte[] getByteArray(String key, byte[] deflt) { argument
296 public double getDouble(String key, double deflt) { argument
301 public float getFloat(String key, float deflt) { argument
306 public int getInt(String key, int deflt) { argument
311 public long getLong(String key, long deflt) { argument
346 public void put(String key, String value) { argument
351 public void putBoolean(String key, boolean value) { argument
356 public void putByteArray(String key, byt argument
361 putDouble(String key, double value) argument
366 putFloat(String key, float value) argument
371 putInt(String key, int value) argument
376 putLong(String key, long value) argument
381 remove(String key) argument
[all...]
/libcore/ojluni/src/main/java/java/lang/
H A DSystem.java907 public Object put(Object key, Object value) { argument
908 if (defaults.containsKey(key)) {
909 logE("Ignoring attempt to set property \"" + key +
911 return defaults.get(key);
914 return super.put(key, value);
918 public Object remove(Object key) { argument
919 if (defaults.containsKey(key)) {
920 logE("Ignoring attempt to remove property \"" + key + "\".");
924 return super.remove(key);
931 String key
1043 setUnchangeableSystemProperty(String key, String value) argument
1178 getProperty(String key) argument
1206 getProperty(String key, String def) argument
1228 setProperty(String key, String value) argument
1249 clearProperty(String key) argument
1255 checkKey(String key) argument
[all...]
/libcore/ojluni/src/main/java/java/security/
H A DSecurity.java109 * provider) mapping the key, if any.
114 private static ProviderProperty getProviderProperty(String key) { argument
122 String prop = prov.getProperty(key);
130 if (key.equalsIgnoreCase(matchKey)) {
149 * Returns the property (if any) mapping the key for the given provider.
151 private static String getProviderProperty(String key, Provider provider) { argument
152 String prop = provider.getProperty(key);
159 if (key.equalsIgnoreCase(matchKey)) {
429 String key = null;
434 key
650 getProperty(String key) argument
684 setProperty(String key, String datum) argument
701 invalidateSMCache(String key) argument
[all...]
/libcore/luni/src/test/java/org/apache/harmony/crypto/tests/javax/crypto/
H A DMacSpiTest.java57 protected void engineInit(Key key, AlgorithmParameterSpec params) throws InvalidKeyException, InvalidAlgorithmParameterException { argument
58 super.engineInit(key, params);
91 protected void engineInit(Key key, AlgorithmParameterSpec params) throws InvalidKeyException, InvalidAlgorithmParameterException { argument
92 super.engineInit(key, params);
130 protected void engineInit(Key key, AlgorithmParameterSpec params) throws InvalidKeyException, InvalidAlgorithmParameterException { argument
131 super.engineInit(key, params);
238 protected void engineInit(Key key, AlgorithmParameterSpec params) argument
H A DCipherSpiTest.java83 protected void engineInit(int opmode, Key key, SecureRandom random) argument
85 super.engineInit(opmode, key, random);
89 protected void engineInit(int opmode, Key key, AlgorithmParameterSpec params, argument
91 super.engineInit(opmode, key, params, random);
95 protected void engineInit(int opmode, Key key, AlgorithmParameters params, argument
97 super.engineInit(opmode, key, params, random);
122 protected int engineGetKeySize(Key key) throws InvalidKeyException { argument
123 return super.engineGetKeySize(key);
127 protected byte[] engineWrap(Key key) throws InvalidKeyException, IllegalBlockSizeException { argument
128 return super.engineWrap(key);
340 engineInit(int opmode, Key key, SecureRandom random) argument
344 engineInit(int opmode, Key key, AlgorithmParameterSpec params, SecureRandom random) argument
349 engineInit(int opmode, Key key, AlgorithmParameters params, SecureRandom random) argument
[all...]
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/nio/channels/
H A DSelectorTest.java105 SelectionKey key = ssc.register(selector, SelectionKey.OP_ACCEPT);
113 assertEquals(key,key2);
164 // add one key into selectedKeys
353 * This test cancels a key while selecting to verify that the cancelled
354 * key set is processed both before and after the call to the underlying
363 final SelectionKey key = pipe.source().register(selector, SelectionKey.OP_READ);
368 // make sure to call key.cancel() while the main thread is selecting
370 key.cancel();
371 assertFalse(key.isValid());
380 assertTrue(key
[all...]
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/
H A DRefSortedMap.java43 final K key; field in class:RefSortedMap.MapEntry
46 MapEntry(K key, V value) { argument
47 this.key = key;
52 return key;
188 public SortedMap<K, V> headMap(K key) { argument
189 if (!isInRange(key)) {
192 return new SubMap(hasStart, start, true, key);
221 public SortedMap<K, V> tailMap(K key) { argument
222 if (!isInRange(key)) {
228 isInRange(K key) argument
278 headMap(K key) argument
294 tailMap(K key) argument
[all...]
/libcore/ojluni/src/main/java/sun/security/ssl/
H A DSSLSessionImpl.java254 // if the private key is no longer valid, getAlgorithm()
618 * key and the calling security context. This is important since
627 public void putValue(String key, Object value) { argument
628 if ((key == null) || (value == null)) {
632 SecureKey secureKey = new SecureKey(key);
638 e = new SSLSessionBindingEvent(this, key);
644 e = new SSLSessionBindingEvent(this, key);
653 public Object getValue(String key) { argument
654 if (key == null) {
658 SecureKey secureKey = new SecureKey(key);
667 removeValue(String key) argument
811 SecureKey(Object key) argument
[all...]
/libcore/json/src/test/java/org/json/
H A DSelfUseTest.java55 @Override public boolean optBoolean(String key, boolean defaultValue) {
57 return super.optBoolean(key, defaultValue);
59 @Override public double optDouble(String key, double defaultValue) {
61 return super.optDouble(key, defaultValue);
63 @Override public int optInt(String key, int defaultValue) {
65 return super.optInt(key, defaultValue);
67 @Override public long optLong(String key, long defaultValue) {
69 return super.optLong(key, defaultValue);
71 @Override public String optString(String key, String defaultValue) {
73 return super.optString(key, defaultValu
[all...]

Completed in 850 milliseconds

1234567891011>>