本文整理了Java中java.util.Dictionary.isEmpty()
方法的一些代码示例,展示了Dictionary.isEmpty()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Dictionary.isEmpty()
方法的具体详情如下:
包路径:java.util.Dictionary
类名称:Dictionary
方法名:isEmpty
[英]Returns true if this dictionary has no key/value pairs.
[中]如果此字典没有键/值对,则返回true。
代码示例来源:origin: org.elasticsearch/elasticsearch
@Override
public boolean isEmpty() {
return sysprops.isEmpty();
}
代码示例来源:origin: apache/felix
@Override
public boolean isEmpty()
{
return delegatee.isEmpty();
}
代码示例来源:origin: org.apache.felix/org.apache.felix.configadmin
@Override
public boolean isEmpty()
{
return delegatee.isEmpty();
}
代码示例来源:origin: de.dentrassi.eclipse.neoscada.utils/org.eclipse.scada.utils.osgi
@Override
public synchronized boolean isEmpty ()
{
return this.dictionary.isEmpty ();
}
代码示例来源:origin: apache/felix
/**
* {@inheritDoc}
*/
public boolean isEmpty() {
return m_dictionary.isEmpty();
}
代码示例来源:origin: org.eclipse.neoscada.utils/org.eclipse.scada.utils.osgi
@Override
public synchronized boolean isEmpty ()
{
return this.dictionary.isEmpty ();
}
代码示例来源:origin: apache/felix
public boolean isEmpty()
{
return events.isEmpty();
}
代码示例来源:origin: org.jboss.gravia/gravia-resource
@Override
public boolean isEmpty() {
return delegate.isEmpty();
}
代码示例来源:origin: org.apache.directory.server/apacheds-protocol-shared
/**
* @see java.util.Map#isEmpty()
*/
public boolean isEmpty()
{
return dictionary.isEmpty();
}
代码示例来源:origin: org.jboss.osgi/jboss-osgi-spi
public boolean isEmpty()
{
return delegate.isEmpty();
}
代码示例来源:origin: xipki/xipki
public static <K,V> Dictionary<K,V> notEmpty(Dictionary<K,V> argument, String name) {
Objects.requireNonNull(argument, name + " may not be null");
if (argument.isEmpty()) {
throw new IllegalArgumentException(name + " may not be empty");
}
return argument;
}
代码示例来源:origin: org.xipki/util
public static <K,V> Dictionary<K,V> notEmpty(Dictionary<K,V> argument, String name) {
Objects.requireNonNull(argument, name + " may not be null");
if (argument.isEmpty()) {
throw new IllegalArgumentException(name + " may not be empty");
}
return argument;
}
代码示例来源:origin: org.opendaylight.tsdr/tsdr-snmp-data-collector
@Override
public void updated(Dictionary<String, ?> properties) throws ConfigurationException {
if (properties != null && !properties.isEmpty()) {
Enumeration<String> k = properties.keys();
while (k.hasMoreElements()) {
String key = k.nextElement();
String[] list = ((String) properties.get(key)).replace("[", "").replace("]", "").split(",");
configurations.put(key, list);
}
}
}
代码示例来源:origin: apache/felix
@Override
public boolean isEmpty() {
return getWrapper().isEmpty();
}
代码示例来源:origin: actframework/actframework
@Override
public void on(DbServiceInitialized event) {
synchronized (asyncInitializers) {
asyncInitializers.remove(event.source());
if (asyncInitializers.isEmpty()) {
daoInitializer.run();
}
}
}
});
代码示例来源:origin: org.actframework/act
@Override
public void on(DbServiceInitialized event) {
synchronized (asyncInitializers) {
asyncInitializers.remove(event.source());
if (asyncInitializers.isEmpty()) {
daoInitializer.run();
}
}
}
});
代码示例来源:origin: org.opendaylight.tsdr/tsdr-datapurge
@Override
public void updated(Dictionary<String, ?> properties) throws ConfigurationException {
if (properties != null && !properties.isEmpty()) {
Enumeration<String> k = properties.keys();
while (k.hasMoreElements()) {
String key = k.nextElement();
String value = (String) properties.get(key);
configurations.put(key, value);
}
PurgingScheduler.getInstance().loadProperties();
PurgingScheduler.getInstance().schedule();
}
}
代码示例来源:origin: SpoonLabs/nopol
@Override
protected Collection<Pair<String, Object>> collectedValues(final String name, final Object value) {
Dictionary<?, ?> dictionary = (Dictionary<?, ?>) value;
Pair<String, Integer> size = Pair.from(name + ".size()", dictionary.size());
Pair<String, Boolean> isEmpty = Pair.from(name + ".isEmpty()", dictionary.isEmpty());
return (Collection) asList(size, isEmpty);
}
代码示例来源:origin: org.pustefixframework/pustefix-core
public List<String> getDefaultSearchModules(ModuleFilter filter) {
List<String> modules = new ArrayList<String>();
for(ModuleDescriptor moduleDesc: commonDefaultSearchModules) {
if(filter == null || moduleDesc.getDefaultSearchFilterAttributes().isEmpty() || filter.accept(moduleDesc.getDefaultSearchFilterAttributes())) {
modules.add(moduleDesc.getName());
}
}
return modules;
}
代码示例来源:origin: org.pustefixframework/pustefix-core
private void getOverridingModules(String moduleName, ModuleFilter filter, String resourcePath, List<String> modules) {
for(ModuleDescriptor moduleDesc:moduleDescMap.values()) {
if((filter == null || moduleDesc.getModuleOverrideFilterAttributes().isEmpty() || filter.accept(moduleDesc.getModuleOverrideFilterAttributes())) && moduleDesc.overridesResource(moduleName, resourcePath)) {
if(!modules.contains(moduleDesc.getName())) {
modules.add(0, moduleDesc.getName());
getOverridingModules(moduleDesc.getName(), filter, resourcePath, modules);
}
}
}
}
内容来源于网络,如有侵权,请联系作者删除!