public synchronized void enable ( ) { ServiceDiscoveryManager . getInstanceFor ( connection ( ) ) . addFeature ( NAMESPACE ) ; StanzaFilter filter = new AndFilter ( OUTGOING_FILTER , new NotFilter ( OUTGOING_FILTER ) ) ; connection ( ) . addStanzaInterceptor ( ADD_ORIGIN_ID_INTERCEPTOR , filter ) ; }
Start appending origin - id elements to outgoing stanzas and add the feature to disco .