本文整理了Java中it.tidalwave.util.logging.Logger
类的一些代码示例,展示了Logger
类的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Logger
类的具体详情如下:
包路径:it.tidalwave.util.logging.Logger
类名称:Logger
暂无
代码示例来源:origin: it.tidalwave.bluebill/it-tidalwave-android-utilities
/*******************************************************************************************************************
*
*
******************************************************************************************************************/
private void dispose (final @Nonnull MediaPlayer oldPlayer)
{
if (oldPlayer != null)
{
logger.fine(">>>> stopping %s...", oldPlayer);
try
{
oldPlayer.stop();
oldPlayer.release();
}
catch (IllegalStateException e)
{
logger.warning("While disposing ", e);
logger.throwing("dispose()", CLASS, e);
}
}
}
}
代码示例来源:origin: it.tidalwave.netbeans/it-tidalwave-netbeans-visual
@Override
public void selectionChanged (final @Nonnull ObjectSceneEvent event,
final @Nonnull Set<Object> previousSelection,
final @Nonnull Set<Object> newSelection)
{
logger.info("selectionChanged(%s, %s, %s)", event, previousSelection, newSelection );
final List<Node> nodes = new ArrayList<Node>();
for (final Object object : newSelection)
{
nodes.add((Node)object);
}
logger.fine(">>>> nodes: " + nodes);
// setActivatedNodes(nodes.toArray(new Node[0]));
try
{
explorerManager.setSelectedNodes(nodes.toArray(new Node[nodes.size()]));
}
catch (PropertyVetoException e)
{
logger.warning("ExplorerManager rejected node selection: %s", e);
logger.throwing(CLASS, "", e);
}
}
代码示例来源:origin: it.tidalwave.netbeans/it-tidalwave-netbeans-actions
/*******************************************************************************************************************
*
* {@inheritDoc}
*
******************************************************************************************************************/
@Override
protected boolean enable (final @Nonnull Node[] nodes)
{
logger.fine("enable(%d nodes) - %s", nodes.length, getClass().getName());
logger.finest(">>>> nodes: %s", Arrays.toString(nodes));
if (!super.enable(nodes))
{
logger.finer(">>>> super() returned false");
return false;
}
for (final T capability : getCapabilities(nodes))
{
if ((capability != null) && !enable(capability))
{
logger.finer(">>>> enable(%s) returning false", capability);
return false;
}
}
logger.finer(">>>> enable() returning true");
return true;
}
代码示例来源:origin: it.tidalwave.metadata/it-tidalwave-metadata-impl
/***************************************************************************
*
*
*
**************************************************************************/
protected MetadataImpl (@Nonnull final DataObject dataObject)
{
logger.fine("MetadataImpl(%s)", dataObject);
if (dataObject == null)
{
throw new IllegalArgumentException("null dataObject");
}
this.dataObject = dataObject;
instanceCount++;
logger.finest("Total number of Metadata instances: %d", instanceCount);
// don't call getLatestModificationTime() now or it will load all items
// oldLatestModificationTime = getLatestModificationTime();
}
代码示例来源:origin: it.tidalwave.bluebill.android/it-tidalwave-mobile-utilities
@Override
public void run()
{
try
{
load();
}
catch (Exception e)
{
setStatus(Status.BROKEN);
logger.severe("While loading %s: %s", url, e);
logger.throwing("download()", CLASS, e);
}
}
}.start();
代码示例来源:origin: it.tidalwave.geo/it-tidalwave-geo-viewer-spi-worldwindprovider
/*******************************************************************************************************************
*
*
******************************************************************************************************************/
private static TextureData readTexture (final @Nonnull URL url, boolean useMipMaps)
{
logger.finer("readTexture(%s, %s)", url, useMipMaps);
try
{
return TextureIO.newTextureData(url, useMipMaps, null);
}
catch (Exception e)
{
logger.severe("Exception reading texture: %s %s", url, e);
logger.throwing(CLASS, "readTexture", e);
return null;
}
}
代码示例来源:origin: it.tidalwave.metadata/it-tidalwave-metadata-impl
@Nonnull
private Format findFormat (@Nonnull final Class<?> itemClass,
@Nonnull final String propertyName)
{
logger.fine("findFormat(%s, %s", itemClass, propertyName);
final MetadataItemFormatProvider formatProvider = formatProviderMapByClass.get(itemClass);
final Format result = (formatProvider != null) ? formatProvider.getFormat(propertyName) : DEFAULT_FORMAT;
logger.finer(">>>> returning %s", result);
return result;
}
}
代码示例来源:origin: it.tidalwave.bluebill/bluebill-mobile-android
/*******************************************************************************************************************
*
*
******************************************************************************************************************/
private static void clearCache()
{
logger.info("clearCache()");
cachedSortedTaxa = null;
cachedSortLocale = null;
}
}
代码示例来源:origin: it.tidalwave.bluebill/it-tidalwave-bluebill-factsheet-xenocanto
@Override
public void flush()
{
logger.fine(buffer.toString());
}
代码示例来源:origin: it.tidalwave.netbeans/it-tidalwave-netbeans-loaders
/*******************************************************************************************************************
*
*
******************************************************************************************************************/
private void fireDataObjectCreated()
{
logger.fine("fireDataObjectCreated() - %s", this);
for (final LifeCycleRole role : getLookupSafelyInConstructor().lookupAll(LifeCycleRole.class))
{
try
{
role.dataObjectCreated(this);
}
catch (Throwable t)
{
logger.throwing(CLASS, "", t);
}
}
}
代码示例来源:origin: it.tidalwave.netbeans/it-tidalwave-netbeans-role
final @Nonnull Lookup injectedLookup)
logger.finest("injectLookup(%s, %s, ...)", role, clazz);
assert injectedLookup != null : "injectedLookup is null";
logger.finest(">>>> injecting field %s...", field);
logger.finest(">>>>>>>> Injecting provider for %s", toInject);
logger.fine("Can't lookup resource: %s", fieldType);
logger.finest(">>>>>>>> injected object is: %s", toInject);
logger.severe("While injecting %s to %s: %s", fieldType, role, e);
logger.throwing(CLASS, "injectLookup()", e);
throw new RuntimeException(e);
代码示例来源:origin: it.tidalwave.bluebill/it-tidalwave-bluebill-mobile-taxonomy
/*******************************************************************************************************************
*
*
******************************************************************************************************************/
private void save()
{
try
{
logger.info("Saving historic taxa to %s...", PERSISTENCE_FILE_NAME);
final ObjectOutputStream oos = new ObjectOutputStream(fileSystem.openFileOutput(PERSISTENCE_FILE_NAME));
oos.writeObject(taxonIdHistory);
oos.close();
}
catch (IOException e)
{
logger.throwing("save()", CLASS, e);
logger.severe("Can't save history: "+ e);
}
}
}
代码示例来源:origin: it.tidalwave.geo/it-tidalwave-geo-viewer-spi-worldwindprovider
/*******************************************************************************************************************
*
*
******************************************************************************************************************/
@Override
public void deactivating()
{
logger.info("deactivating() - clearing memory cache");
try
{
// See http://issues.worldwind.arc.nasa.gov/browse/WWJ-50
// but it doesn't work
worldWindow.getTextureCache().clear();
}
catch (Exception e)
{
logger.warning(e.toString());
logger.throwing(CLASS, "deactivating()", e);
}
super.deactivating();
}
代码示例来源:origin: it.tidalwave.metadata/it-tidalwave-metadata-viewer
logger.info("setDataObject(%s)", dataObject);
final long time = System.currentTimeMillis();
logger.fine(">>>> metadata: %s", metadata);
logger.fine(">>>> holder: %s", holder);
pane.bind(holder);
logger.severe(String.format("Could not bind item, because of %s", e));
logger.severe(String.format("Could not bind item, because of %s", e));
logger.fine(">>>> setDataObject() completed in %d msec", System.currentTimeMillis() - time);
代码示例来源:origin: it.tidalwave.netbeans/it-tidalwave-netbeans-loaders
/*******************************************************************************************************************
*
*
******************************************************************************************************************/
@Override
protected void finalize()
{
count--;
logger.finest("Total number of EnhancedMultiDataObject instances: %d", count);
}
代码示例来源:origin: it.tidalwave.netbeans/it-tidalwave-netbeans-actions
/*******************************************************************************************************************
*
* {@inheritDoc}
*
******************************************************************************************************************/
@Override
public final void performAction (final @Nonnull Node[] nodes)
{
try
{
performAction(getCapabilities(nodes));
}
catch (Exception e)
{
logger.warning("Exception in performAction(): %s", e);
logger.throwing(CLASS, "performAction()", e);
e.printStackTrace();
}
}
代码示例来源:origin: it.tidalwave.semantic/it-tidalwave-openrdf-elmo
final @Nonnull EntityInitializer<I> initializer)
logger.finer("create(%s, %s)", qName, initializer);
if (logger.isLoggable(Level.FINEST))
logger.finest(">>>> implementationClass: %s extraClasses: %s", implementationClass, Arrays.toString(extraClasses));
logger.severe("Bad entity: created class subclass of: %s interfaces: %s",
createdClass.getSuperclass(),
Arrays.toString(createdClass.getInterfaces()));
代码示例来源:origin: it.tidalwave.bluebill/it-tidalwave-bluebill-mobile-taxonomy
/*******************************************************************************************************************
*
*
******************************************************************************************************************/
@Nonnull
public List<Taxon> getRecentTaxa()
{
logger.info("getRecentTaxa()");
final List<Taxon> taxa = new ArrayList<Taxon>();
final Taxonomy taxonomy = Locator.find(TaxonomyPreferences.class).getTaxonomy();
for (final Id taxonId : taxonIdHistory)
{
try
{
taxa.add(taxonomy.findTaxa().withId(taxonId).result());
}
catch (NotFoundException e)
{
logger.warning("Can't retrieve taxon for id: %s", taxonId);
}
}
return taxa;
}
代码示例来源:origin: it.tidalwave.semantic/it-tidalwave-openrdf-elmo
/*******************************************************************************************************************
*
*
******************************************************************************************************************/
private void sanityCheck (final @Nonnull Method method)
{
if (!method.getDeclaringClass().isAssignableFrom(entityDelegate.getClass()))
{
logger.warning("Mismatch: entity class %s, method class: %s, instanceof %s",
entityDelegate.getClass(),
method.getDeclaringClass(),
Arrays.toString(entityDelegate.getClass().getInterfaces()));
}
}
}
代码示例来源:origin: it.tidalwave.metadata/it-tidalwave-metadata-impl
@Override
public void propertyChange (@Nonnull final PropertyChangeEvent event)
{
logger.finer("propertyChange(%s)", event);
// if (event.getPropertyName().endsWith("Available")) // TODO
// {
// firePropertyChange("available", oldAvailable, isAvailable());
// }
//
// FIXME: this is disabled since it gets called from the setting of beans
// Probably you should not bind beans to listener BEFORE populating them for the first time.
// when they are read from the database and trigger spurious operations.
// if (event.getPropertyName().equals(PROP_LATEST_MODIFICATION_TIME))
// {
// final Date latestModificationTime = getLatestModificationTime();
// firePropertyChange(PROP_LATEST_MODIFICATION_TIME, oldLatestModificationTime, latestModificationTime);
// oldLatestModificationTime = latestModificationTime;
// }
}
};
内容来源于网络,如有侵权,请联系作者删除!