Geekius Caesar wrote:
I assume that I will have to create an OtrActivator and an
Ineed, you'd need those.
I also assume that I have to build an
OperationSetInstantMessageTransform for each ProtocolProviderService
(for example OperationSetInstantMessageTransformJabberImpl), and put
it in the supportedOperationSets.
Correct again. Only you'd need to do this for all protocols and not only
Jabber I am afraid.
It may also be worth considering adding the implementation of
OperationSetInstantMessageTransform inside the
OperationSetBasicInstantMessagingXxxImpl classes. This would make
transformers easier to use.
Then, in OperationSetBasicInstantMessagingJabberImpl, in sendMessage I
will have to query the jabberProvider for a
OperationSetInstantMessageTransform and transform the message to be
sent. Am I thinking it correctly up till here?
Well depends on how you implement it. If you follow my suggestion from
above then you would simply need to check whether any there have been
any transform layers added to your local transofmers list.
So, to my understanding, OperationSetInstantMessageTransform has to
have a method to return all TransformLayers sorted by priority. Should
this method be added in the interface
OperationSetInstantMessageTransform and maybe implement it in an
Not that OperationSet-s are meant for bundles _other_ than the protocol
providers to access functionality _within_ the protocol providers. You
don't need to us the interface within the protocol provider.
Adding a method that returns all TransformLayer-s could probably still
be useful for some reason (even though I can't really come up with an
use case right now) but that reason isn't its usage from the protocol
OtrActivator's job would simply be to attach the
OtrTransformationLayer in the OperationSetInstantMessageTransform of
all ProtocolProviderService, correct? That can happen when
OtrActivator starts and when a ProtocolProviderService is added (so it
must implement ServiceListener).
It would also be up to the Activator to register the OTR configuration
UI into the ConfigurationForm.
Thank you for your time reading and answering this,
You are most welcome!
To unsubscribe, e-mail: firstname.lastname@example.org
For additional commands, e-mail: email@example.com