public String getInitializationParameter(String name) { return (String)getInitializationParameters().get(name); }
public void setMessageHandlers(Collection handlers) { Iterator i = handlers.iterator(); while (i.hasNext()) setMessageHandler((MessageHandler)i.next()); }
public void setResource(Resource resource) { Class theClass = resource.getClass(); // // sanity check - only ws-resources should use ws-rf // if (!WsResource.class.isAssignableFrom(theClass)) { Object[] filler = { theClass, WsResource.class }; throw new RuntimeException(_MESSAGES.get("NotWSRF", filler)); } super.setResource(resource); }
public void initialize() throws SoapFault { super.initialize(); setMessageHandler(createGetMetadataHandler()); } }
public void initializeCompleted() throws SoapFault { Persistence persistence = getPersistence(); // // if the capability defines a persistence mechanism, we // should ask it to reload any saved data // if (persistence != null) { ResourceManager manager = getResource().getResourceManager(); persistence.setResourceManager(manager); persistence.reload(); } }
public void initializeCompleted() throws SoapFault { super.initializeCompleted(); Resource resource = getResource(); // // this allows the advertisement capability to hear about // all resource lifecycle events that happen in the application // ResourceManager manager = resource.getResourceManager(); manager.addListener(this); // // initialize the advertisement topics // NotificationProducer wsn = (NotificationProducer)resource.getCapability(WsnConstants.PRODUCER_URI); wsn.addTopic(MuwsConstants.ADV_ME_CREATION_TOPIC); wsn.addTopic(MuwsConstants.ADV_ME_DESTRUCTION_TOPIC); // // create subscriptions for all event consumer that are going to // receive notifications from the above topics // subscribeInitialConsumer(); }
public void initialize() throws SoapFault { super.initialize(); // // add NotificationMessage to the collection of serializable types in // case the user forgot to put it in muse.xml // SerializerRegistry registry = SerializerRegistry.getInstance(); registry.registerSerializer(NotificationMessage.class, new NotificationMessageSerializer()); // // add message handler for <Notify/>, which has array parameters // that are outside our WSDL conventions // setMessageHandler(createNotifyHandler()); }
throws SoapFault super.initialize();