本文整理汇总了Java中org.apache.felix.ipojo.annotations.Invalidate类的典型用法代码示例。如果您正苦于以下问题:Java Invalidate类的具体用法?Java Invalidate怎么用?Java Invalidate使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
Invalidate类属于org.apache.felix.ipojo.annotations包,在下文中一共展示了Invalidate类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: stop
import org.apache.felix.ipojo.annotations.Invalidate; //导入依赖的package包/类
/**
* Callback to clean-up after departure of required resources
*/
@Invalidate
public void stop() {
synchronized (this) {
this.started = false;
}
PropertyManagement propertyManagement = ServiceLocator.instance().getService(
PropertyManagement.class);
propertyManagement.removeObjectPropertyFilter(PropertyType.NoteProperty,
ActivityService.PROPERTY_KEY_GROUP, ActivityService.NOTE_PROPERTY_KEY_ACTIVITY);
propertyManagement.removeObjectPropertyFilter(PropertyType.NoteProperty,
ActivityService.PROPERTY_KEY_GROUP,
ActivityService.NOTE_PROPERTY_KEY_ACTIVITY_UNDELETABLE);
TaskManagement taskManagement = ServiceLocator.instance().getService(TaskManagement.class);
taskManagement.removeTaskHandler(DeleteActivitiesTaskHandler.class.getName());
}
示例2: invalidate
import org.apache.felix.ipojo.annotations.Invalidate; //导入依赖的package包/类
/**
* Component invalidated
*/
@Invalidate
public void invalidate() {
// Destroy end points
final ExportEndpoint[] endpoints = pEndpoints.values().toArray(
new ExportEndpoint[0]);
for (final ExportEndpoint endpoint : endpoints) {
try {
// Release the service, unregister the endpoint
unexportService(endpoint);
} catch (final Exception ex) {
// Just log the error
pLogger.log(LogService.LOG_WARNING,
"Error unregistering service: " + ex, ex);
}
}
// Clean up
pLocalUid = null;
pJsonRpcBridge = null;
}
示例3: invalidate
import org.apache.felix.ipojo.annotations.Invalidate; //导入依赖的package包/类
/**
* Component invalidated
*/
@Invalidate
public void invalidate() {
if (pMulticast != null) {
try {
pMulticast.stop();
} catch (final IOException ex) {
pLogger.log(LogService.LOG_ERROR,
"Error stopping the multicast receiver", ex);
}
pMulticast.setLogger(null);
pMulticast = null;
}
pLogger.log(LogService.LOG_INFO, "Multicast broadcaster gone");
}
示例4: stop
import org.apache.felix.ipojo.annotations.Invalidate; //导入依赖的package包/类
@Invalidate
public void stop() {
for (int id : queries.keySet()) {
Query query = queries.get(id);
if (query != null) {
logger.info("araqne logdb: cancel query [{}:{}] due to service down", id, query.getQueryString());
removeQuery(id);
}
}
if (accountService != null) {
accountService.removeListener(this);
}
if (queryParserService != null) {
for (QueryCommandParser p : queryParsers)
queryParserService.removeCommandParser(p);
}
}
示例5: stop
import org.apache.felix.ipojo.annotations.Invalidate; //导入依赖的package包/类
@Invalidate
public void stop() {
reject = true;
// wait until file sync is done
try {
sync.doStop = true;
sync.join();
sync = null;
slog.info("araqne log api: state thread ended");
} catch (InterruptedException e) {
slog.warn("araqne log api: last state sync thread join interrupted", e);
}
}
示例6: stop
import org.apache.felix.ipojo.annotations.Invalidate; //导入依赖的package包/类
/**
* removes the activities
*/
@Invalidate
public void stop() {
// activityService might be or get invalid -> remove all
for (EventListener<? extends Event> listener : eventListeners) {
eventDispatcher.unregister(listener);
}
eventListeners.clear();
if (activityService != null) {
for (ActivityDefinition activity : activities) {
activityService.removeDefinition(activity.getTemplateId());
}
}
}
示例7: close
import org.apache.felix.ipojo.annotations.Invalidate; //导入依赖的package包/类
@Invalidate
public void close() {
if (internalMessageProducer != null) {
try {
internalMessageProducer.close();
} catch (JMSException e) {
LOGGER.error("Error closing internalMessageProducer " + e.getMessage(), e);
}
internalMessageProducer = null;
}
}
示例8: stopConsumerFactory
import org.apache.felix.ipojo.annotations.Invalidate; //导入依赖的package包/类
/**
* is invoked to properly stop the factory
*/
@Invalidate
public void stopConsumerFactory() {
Set<ProviderMessageConsumer> messageConsumers = jmsMessageConsumers
.keySet();
for (ProviderMessageConsumer messageConsumer : messageConsumers) {
jmsMessageConsumers.get(messageConsumer).stop();
jmsMessageConsumers.put(messageConsumer, null);
}
LOG.info("JMS Consumer Factory was stopped");
}
示例9: deactivate
import org.apache.felix.ipojo.annotations.Invalidate; //导入依赖的package包/类
@Invalidate
protected void deactivate()
{
SwingUtils.invokeLater(new Runnable() {
public void run() {
setVisible(false);
dispose();
}
});
}
示例10: invalidate
import org.apache.felix.ipojo.annotations.Invalidate; //导入依赖的package包/类
/**
* Component invalidated
*/
@Invalidate
public void invalidate() {
// Clean up
pJidPeer.clear();
pGroups.clear();
}
示例11: invalidate
import org.apache.felix.ipojo.annotations.Invalidate; //导入依赖的package包/类
/**
* Component invalidated
*/
@Invalidate
public void invalidate() {
// Clear the bot
pBot.disconnect();
pBot = null;
// Clean up members
pContact.clear();
pContact = null;
pMucDomain = null;
}
示例12: invalidate
import org.apache.felix.ipojo.annotations.Invalidate; //导入依赖的package包/类
/**
* Component gone
*/
@Invalidate
public void invalidate() {
// Kill'em all
stopComponent();
}
示例13: invalidate
import org.apache.felix.ipojo.annotations.Invalidate; //导入依赖的package包/类
/**
* Component invalidated
*/
@Invalidate
public void invalidate() {
// Clean up
pUidAddress.clear();
}
示例14: invalidate
import org.apache.felix.ipojo.annotations.Invalidate; //导入依赖的package包/类
/**
* Component invalidated
*/
@Invalidate
public void invalidate() {
pContact.clear();
pContact = null;
}
示例15: invalidate
import org.apache.felix.ipojo.annotations.Invalidate; //导入依赖的package包/类
@Invalidate
public void invalidate() {
pController = false;
pHttpPort = -1;
if (pTimer != null) {
pTimer.cancel();
pTimer = null;
}
}